My Son's science experiment help request.

MiniPOV, MiniPOV2 and MiniPOV3

Moderators: adafruit_support_bill, adafruit

My Son's science experiment help request.

Postby aurbo99 » Wed Feb 04, 2009 1:00 pm

Hi

My Son is trying to create an experiment using the POV to determine whether or not the human mind can make order of seemingly random patterns.

While the answer is known.. Yes. the POV prooves it. He has a different approach which is can the human mind make the same connection for the patterns (words) if they are in a different language.

Meaning, if you cannot speak,read,understand.. say French, and the POV is programmed with a French word, will your mind sort it out. not bad for a 12 year old..

I am not a linguist, so here I am.. Can I get a few of you to respond with respectable words in other languages and its english conversion so he can pick a few to use with his experiment.

On slightly different topic, is there enough room to hold 2 words in the code, and by using a jumper connected to a pair of the PD0-PD6 pins have it display word 1 or word 2?

Any assistance would be appreciated.
Steve
aurbo99
 
Posts: 14
Joined: Sat Mar 01, 2008 7:16 am

Re: My Son's science experiment help request.

Postby magician13134 » Wed Feb 04, 2009 1:26 pm

As far as choosing words, I would choose words in English first then go here to translate them.
And for storing two pictures (words), that sure, but it would require just a little work. Since you can store several hundred lines, and a word my require only 50 or so, this should be no problem. I don't have the files in front on me at the moment, but there is a file called "sensor.c" if I remember correctly. I would use this code as your base, and just solder in a jumper to the sensor pins.
User avatar
magician13134
 
Posts: 1119
Joined: Wed Jun 13, 2007 8:17 am
Location: Ann Arbor

Re: My Son's science experiment help request.

Postby aurbo99 » Wed Feb 04, 2009 1:38 pm

Thanks =)
aurbo99
 
Posts: 14
Joined: Sat Mar 01, 2008 7:16 am

Re: My Son's science experiment help request.

Postby mtbf0 » Wed Feb 04, 2009 1:46 pm

since a word in a foreign language is essentially a string of random characters to one who cannot read it, strings of random characters should suffice for your experiment.
"i want to lead a dissipate existence, play scratchy records and enjoy my decline" - iggy pop, i need more
User avatar
mtbf0
 
Posts: 1642
Joined: Fri Nov 09, 2007 11:59 pm
Location: oakland ca

Re: My Son's science experiment help request.

Postby mtbf0 » Wed Feb 04, 2009 1:46 pm

... or how about a pov eye chart?
"i want to lead a dissipate existence, play scratchy records and enjoy my decline" - iggy pop, i need more
User avatar
mtbf0
 
Posts: 1642
Joined: Fri Nov 09, 2007 11:59 pm
Location: oakland ca

Re: My Son's science experiment help request.

Postby aurbo99 » Wed Feb 04, 2009 4:32 pm

mtbf0 wrote:since a word in a foreign language is essentially a string of random characters to one who cannot read it, strings of random characters should suffice for your experiment.


True, but there's the part where a person that understands that particular language will correctly identify the word where someone who does not understand that language may only give you letters.

example:
English = salute <-- English will respond with "to salute" like a soldier
French = salute <-- French (French Canadian) will respond with "Hi" a slang term for Hello <will the mind process the 'e' at the end?>
What would a bilingual Eng/Fre interpret the word as? one, the other, or both?

Arabic = تحية <-- Arabic will respond with ? <I dont have the answer myself, I dont understand Arabic! would I even recognize this as a word?>
aurbo99
 
Posts: 14
Joined: Sat Mar 01, 2008 7:16 am

Re: My Son's science experiment help request.

Postby aurbo99 » Mon Feb 09, 2009 5:09 pm

Regarding the resistors in the circuit diagram.

R21 states a 200ohm Is it a critical value? (I dont have one) would a 180 or a 220 work in its place?
aurbo99
 
Posts: 14
Joined: Sat Mar 01, 2008 7:16 am

Re: My Son's science experiment help request.

Postby magician13134 » Mon Feb 09, 2009 8:33 pm

Most resistors have + 10% accuracy, so your 200 Ohm could have a fairly reasonable chance of being less than a resistor marked 180 Ohm or higher than one marked 220 Ohm. It shouldn't matter
User avatar
magician13134
 
Posts: 1119
Joined: Wed Jun 13, 2007 8:17 am
Location: Ann Arbor

Re: My Son's science experiment help request.

Postby aurbo99 » Mon Feb 09, 2009 8:52 pm

Thanks for the info,
aurbo99
 
Posts: 14
Joined: Sat Mar 01, 2008 7:16 am

Re: My Son's science experiment help request.

Postby aurbo99 » Mon Feb 09, 2009 9:01 pm

Running to MiniPOV.exe file it generates the file.

When I load it it seems to only display one or two letters of the word.

Any clues?

LPT version POV2
Home etched

only thing not stock is the 220Ohm instead of the 200Ohm

Code: Select all
#include <avr/io.h>      // this contains all the IO port definitions
#include <avr/interrupt.h>
#include <avr/signal.h>
#include <avr/pgmspace.h>
#include <util/delay.h>

void delay_ms( uint16_t milliseconds)
{
   for( ; milliseconds > 0; milliseconds--)
   {
      _delay_ms( 1);
   }
}

#define TIMER1_PRESCALE_1 1
#define TIMER1_PRESCALE_8 2
#define TIMER1_PRESCALE_64 3
#define TIMER1_PRESCALE_256 4
#define TIMER1_PRESCALE_1024 5


// We use these macros because binary constants arent always supported. ugh.
#define HEX__(n) 0x##n##UL
#define B8__(x) ((x&0x0000000FLU)?1:0)  \
               +((x&0x000000F0LU)?2:0)  \
               +((x&0x00000F00LU)?4:0)  \
               +((x&0x0000F000LU)?8:0)  \
               +((x&0x000F0000LU)?16:0) \
               +((x&0x00F00000LU)?32:0) \
               +((x&0x0F000000LU)?64:0) \
               +((x&0xF0000000LU)?128:0)
#define B8(d) ((unsigned char)B8__(HEX__(d)))


// store all the image data in program memory (ROM)
// instead of RAM (the default)
const uint8_t large_image[] PROGMEM = {
B8(00000000),
B8(01111100),
B8(10000010),
B8(10000010),
B8(10100010),
B8(01100110),
B8(00100000),
B8(00000000),
B8(01110000),
B8(10001000),
B8(10001000),
B8(10001000),
B8(01110000),
B8(00000000),
B8(00000000),
B8(01110000),
B8(10001000),
B8(10001000),
B8(10001000),
B8(01110000),
B8(00000000),
B8(00000000),
B8(01110000),
B8(10001000),
B8(10001000),
B8(10010010),
B8(11111110),
B8(10000000),
B8(00000000),
B8(00000000),
B8(00000000),
B8(00000000),
B8(00000000),
B8(00000000),
B8(00000000),
B8(10001000),
B8(11111000),
B8(10010000),
B8(00001000),
B8(10001000),
B8(11110000),
B8(10000000),
B8(00000000),
B8(10001000),
B8(10001000),
B8(11111010),
B8(10000000),
B8(10000000),
B8(00000000),
B8(00000000),
B8(00011100),
B8(10100010),
B8(10100010),
B8(10100100),
B8(01111110),
B8(00000010),
B8(10000010),
B8(11111110),
B8(10010000),
B8(00001000),
B8(10001000),
B8(11110000),
B8(10000000),
B8(00001000),
B8(01111100),
B8(10001000),
B8(10001000),
B8(10001000),
B8(01000000),
B8(00000000),
B8(00000000),
};

// special pointer for reading from ROM memory
PGM_P largeimage_p PROGMEM = large_image;

#define NUM_ELEM(x) (sizeof (x) / sizeof (*(x)))
int imagesize = NUM_ELEM(large_image);



// this function is called when timer1 compare matches OCR1A
uint8_t j = 0;
SIGNAL( SIG_TIMER1_COMPA ) {
  if (j >= imagesize)
    j = 0;

  // read the image data from ROM
  PORTB = pgm_read_byte(largeimage_p + j);

  j++;
}

int main(void) {

  DDRB = 0xFF;       // set all 8 pins on port B to outputs

  /*
    the frequency of the interrupt overflow is determined by the
    prescaler and overflow value.
    freq = clock_frequency / ( 2 * prescaler * overflow_val)
    where prescaler can be 1, 8, 64, 256, or 1024
    clock_freq is 8MHz
    and overflow_val is 16bit

    the overflow value is placed in OCR1A, the prescale is set in TCCR1B
    so for example:
    A good POV frequency is around 400Hz
    desired freq = 400Hz
    clock freq = 8MHz
    8MHz / (400Hz * 2) = 10000
    since 10000 is less than 655536 (largest 16 bit number)
    OCR1A = 10000 and the prescale is 1
  */

  TCCR1B = (1 << WGM12) | TIMER1_PRESCALE_1;
  OCR1A = (uint16_t)10000;

  TIMSK |= 1 << OCIE1A;   // Output Compare Interrupt Enable (timer 1, OCR1A)

  sei();                 // Set Enable Interrupts

  while (1);
}

Last edited by aurbo99 on Mon Feb 09, 2009 9:04 pm, edited 1 time in total.
aurbo99
 
Posts: 14
Joined: Sat Mar 01, 2008 7:16 am

Re: My Son's science experiment help request.

Postby magician13134 » Mon Feb 09, 2009 9:03 pm

Can you put the code it generated into a
Code: Select all
[code][/code]
tag?
User avatar
magician13134
 
Posts: 1119
Joined: Wed Jun 13, 2007 8:17 am
Location: Ann Arbor

Re: My Son's science experiment help request.

Postby aurbo99 » Mon Feb 09, 2009 9:16 pm

I was just doing that when you posted.. =)
aurbo99
 
Posts: 14
Joined: Sat Mar 01, 2008 7:16 am

Re: My Son's science experiment help request.

Postby aurbo99 » Mon Feb 09, 2009 9:48 pm

Carefully reviewing our setup, traces, solder joint and parts.

We are using a 20PU on the POV2 and a 10PU on the POV3

while the text is working fine on the 10PU, the 20PU does not like the speed or something.

Swapping the chips between units and programming several different words proves to me at least the 20PU is the issue.

What can be done to allow the 20PU to work like the 10PU?
aurbo99
 
Posts: 14
Joined: Sat Mar 01, 2008 7:16 am

Re: My Son's science experiment help request.

Postby magician13134 » Mon Feb 09, 2009 9:50 pm

Hmm, the code looks fine. Are the firmware for the MiniPOV2 and 3 the same? You may want to open one of the sample codes (use largeimage.c I think it's called) and just copy all the "B8(.......);"s over the ones in that code.

Oh. After reading your last post... Did you burn the same fuses on each one? I'm not sure if they're supposed to be the same or not... That was really helpful :)
Fuses have always been my Achilles' Heel...
User avatar
magician13134
 
Posts: 1119
Joined: Wed Jun 13, 2007 8:17 am
Location: Ann Arbor

Re: My Son's science experiment help request.

Postby aurbo99 » Mon Feb 09, 2009 10:01 pm

Burning a new 10PU, its now acting like the 20PU..

Perhaps I've not set the fuses right.


Lost...
aurbo99
 
Posts: 14
Joined: Sat Mar 01, 2008 7:16 am

Next

Return to MiniPOV

Who is online

Users browsing this forum: mibignistinly and 0 guests

Stuff to buy from the Adafruit store and links to product documentation!


New Products [114]

Raspberry Pi[82]
 
FLORA[24]
 
Bunnie Studios[9]
 
FPGA[1]
 
mbed[12]
Arduino[60]
 
NETduino[14]
 
BeagleBone[23]
 
Android[6]
 
XBee[10]
More Dev Boards[30]


 
BoArduino[8]
 
SpokePOV[4]
 
TV-B-Gone[4]
 
MiniPOV[3]
 
SIM reader[3]
 
Microtouch[5]
 
Clocks & Watches[18]
 
Drawdio[4]
 
Brain Machine[1]
 
Game of Life[2]
 
MintyBoost[2]
More DIY Kits[16]


 
MaKey MaKey[3]
 
Tweet-a-Watt[5]
 
Young Engineers[39]
 
Discover Electronics[2]
 
Snap Circuits[4]
 
littleBits[3]
 
Project packs[9]


 
Breakout Boards[35]
LCDs & Displays[49]
Components & Parts[70]
Batteries & Power[54]
EL Wire/Tape/Panel[52]
LEDs[112]
 
Wireless[16]
Cables[66]
 
Lasers[6]
Sensors/Parts[147]
 
Enclosures/Cases[11]
 
Solar[11]
 
RFID / NFC[13]
Prototyping[70]
 
iDevices[13]
Tools[71]
 
Wearables[41]
 
CNC[37]
 
Robotics[29]
 
3D printing[1]
 
Materials[25]


 
Stickers[41]
 
Skill badges[55]
 
Books[26]
 
Circuit Playground[7]
 
Gift Certificates[4]