Show Posts
Pages: [1] 2 3 ... 6
1  Using Arduino / Project Guidance / Re: RFID(CR003t) Not working with uno on: June 15, 2013, 02:13:59 am
Looks good... I might give that a go if they can ship from China.

I checked all these and nobody seems to have any 13.56MHz readers:

http://robokits.co.in/
http://www.simplelabs.co.in/
http://www.robosoftsystems.co.in/
http://shop.sumeetinstruments.com/
http://store.explorelabs.com/
http://www.mgsuperlabs.co.in/

http://www.rhydolabz.com/ do actually list a couple of parts but they're out of stock.

If I'm missing any of the "usual suspects" for sourcing electronics, I would appreciate some pointers... thx!

2  Using Arduino / Project Guidance / Re: RFID(CR003t) Not working with uno on: June 15, 2013, 01:39:16 am
OK according to this PDF I just found, the tokens are ISO 14443 so I guess the Smartcards are as well.

http://www.delhimetrorail.com/otherdocuments/515/CS29A.pdf

next question: where to get a 13.56MHz reader from in India?

And what's the hobby shop you used in Delhi?   I've only been here a few months and haven't located the geek shops yet smiley

3  Using Arduino / Project Guidance / Re: RFID(CR003t) Not working with uno on: June 15, 2013, 01:28:57 am
Thanks but I want to read the Metro smartcards and tokens.

Have you tried using a 13MHz reader with them?

4  Using Arduino / Project Guidance / Re: RFID(CR003t) Not working with uno on: June 14, 2013, 11:33:52 pm
Hey akshaykirti

Did you get your reader to read tokens or smartcards from the Delhi metro?

If so, which one are you using, or what frequency do the tags use?  125kHz, 13MHz or something else?

Many thanks!
5  Community / Local Groups / Re: Arduino Uno Training in Bangalore on: February 17, 2011, 11:51:56 pm
This is short notice but I only just found out myself...

This is tomorrow at Jaaga http://www.jaaga.in/events

Sat, February 19, 9am – 5pm

Monthly meetup of members of Computer Club of India - http://groups.google.com/group/computerclubin.

We gather to share their learnings and work on hacking up cool hardware/ software projects together. Vinay wi'll be doing the Atmel circuit workshop he did last time. He is also looking at working on some basic soldering.

Sudar Muthu - http://SudarMuthu.com will take responsibility of the Arduino track showing some small experiments about using Arduino and some of his projects as well.


Jaaga is in Bangalore city, near the Hockey Stadium.
6  Community / Local Groups / Re: Bangalore / India? on: February 17, 2011, 11:44:45 pm
OK, so any suggestions for Bangalore shops in the "local electronics market" if I just want to stock up on some basics to use with some students?

i.e. breadboards, multi-packs of resistors and capacitors, potentiometers, wire-strippers, soldering irons and selection of switches and sensors like LDRs, IR distance, tilt switches etc...

I've heard of Om Electronics - can I get all this stuff there?

As for getting conned I know the subject very well, but am a foreigner and have no idea of local prices so I guess I have no chance!  smiley-roll

thanks


7  Community / Local Groups / Bangalore / India? on: February 08, 2011, 01:58:20 am
hi all,

There was some discussion of a group in Bangalore last year but it's now read-only...

I just relocated to BLR from the UK and now have zero equipment except for the single duemilanove I threw in my suitcase.   smiley-sad

I'm wondering where Bangaloreans or Indians in general would look for components and equipment... do you all buy stuff on-line, or are there hobbyist/professional electronics suppliers in town? 

I've already found these guys btw:

http://build.simplelabs.co.in/
http://www.bhasha.co.cc/
http://www.rhydolabz.com/

...but will also need a proper India-based supplier with a wider range of components similar to Farnell, Digikey, Conrad etc.

Thanks!
8  Forum 2005-2010 (read only) / Troubleshooting / Re: Uploading a .hex file using avrdude not in sync er on: November 24, 2009, 03:37:46 pm
er yeah that was me...  Thanks condemned/nigel/keith/whichever brother you are! smiley

I meant to document all of this back in the summer but never got round to it...

I was using the hacked version of avrdude supplied with Luminet version of Arduino IDE, which has/had bitbang-based .hex file programming built-in. http://hci.rwth-aachen.de/luminet

I use a mac and at the time (this might still be true) there was an issue with the Mac FTDI driver, since it uses VCP and avrdude doesn't like this. (thanks to René Bohne for help with this!)

From what I can gather looking at the scant documentation I made, I ended up resorting to running windows under parallels, and using the windows version of the avrdude distributed with Luminet like this:

C:\luminet\Windows\hardware\tools\avr\bin> avrdudeFTDI -C ../etc/avrdudeFTDI.conf -v -v -v -v -pm168 -cdiecimila -Pft0 -B4800 -e -Uefuse:w:0x01:m -Uhfuse:w:0xdf:m -Ulfuse:w:0xff:m

C:\luminet\Windows\hardware\tools\avr\bin> avrdudeFTDI -C ../etc/avrdudeFTDI.conf -v -v -v -v -pm168 -cdiecimila -Pft0 -B4800 -e -U flash:w:TellyMate_M168.hex


The first one sets the fuses, while the second one burns the hex file.   I got the fuse values from the batch file M168_program_all.bat on the batsocks website.  I guess you can do something similar for non-168 based arduinos.

In terms of wiring I used the common hack at http://www.geocities.jp/arduino_diecimila/bootloader/index_en.html including soldering a 4-way header onto the board.

caveat: this info is now a whole 5 months old and so could be hideously outdated by now...

cheers,

pixelfrenzy/mungbean/chris


9  Forum 2005-2010 (read only) / Troubleshooting / Re: Snow Leopard and ArduinoBT on: August 29, 2009, 12:49:37 pm
I just dug out my ancient ARDUINOBT and am having similar issues on OSX Leopard 10.5.8, with arduino 0017.

I'm not sure if it's a problem with stale lock files being left around, but I found that opening terminal and running screen to connect to the serial port, closing it again was fixing the messages about Serial port already in use (or I/O error from avrdude when programming).

in my case I did this:

$ screen /dev/tty.ARDUINOBT-BluetoothSeri-1

(receive output from arduino board)

(control-a, control-\ to quit.)

this seems to return the BT serial port to a sensible state.  works while IDE running, so long as the serial monitor window isn't open.

Still a PITA to upload code to this thing though... is there a newer bootloader (mine's >2 yrs old), or did people pretty much give up on the BT board?

10  Forum 2005-2010 (read only) / Bugs & Suggestions / YaBB search -> 500 error on: February 17, 2009, 12:03:03 pm
I'm getting 500 server config error when trying to search the forums just now...

presumably there will be something in the log files to explain it.


chris
11  Forum 2005-2010 (read only) / Bugs & Suggestions / Re: Arduino 0011 and <stdio.h> on: June 18, 2008, 02:29:22 pm
it's to do with the redefinition of 'int' IIRC... something being tried out in v11 .

Mellis posted about this as soon as v11 came out, but I can't seem to find the posting at present.

undefining the int macro before the include will fix it...

Code:
#undef int
#include <stdio.h>

12  Forum 2005-2010 (read only) / Bugs & Suggestions / Re: delayclockcycle() on: April 24, 2008, 03:21:11 pm
Quote
Check the GCC Inline Assembler HOWTO. http://www.ibiblio.org/gferg/ldp/GCC-Inline-Assembly-HOWTO.html and the Atmel AVR-8 instruction set.

That link uses the x86 instruction set, which is potentially rather confusing smiley  (Or at least it had me scratching my head at 2am....)

The AVR-specific equivalent, include a list of opcodes and constraints is at http://www.nongnu.org/avr-libc/user-manual/inline_asm.html

Plus  more links and some of my ramblings about getting started with inline assembler over at http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1207370768/2#2
13  Forum 2005-2010 (read only) / Syntax & Programs / Re: Accessing registers in Arduino? on: April 30, 2008, 07:34:27 pm
Ah, that's good info -- thanks mem!

What's the thinking on using the _SFR_ format of macros for referring to registers...?  

Or, to put it another way, what's the preferred way to refer to ports etc. to allow portability between various models of processors?

cheers
14  Forum 2005-2010 (read only) / Syntax & Programs / Re: Embedding Assembly in C++ on: April 24, 2008, 02:32:48 pm
OK I'm working through this slowly while doing several other things (as usual).

So it looks like yes -- you can pass in and modify global variables.

Code:
unsigned int a = 0;

void setup() {
  Serial.begin(9600);

  a = 2;

  Serial.print("a = ");
  Serial.println(a);

    asm("mov r0,%0 \n\t"  // copy a to r0
      "inc r0    \n\t"  // increment  
      "inc r0    \n\t"  // increment    
      "mov %0,r0 \n\t"  // copy r0 back to a
      :  "+r" (a));

  Serial.print("now a = ");
  Serial.println(a);

}

void loop() {
}

It took me a while to understand the syntax of asm() because it's weird and it was too late at night.  :-[

If all you want to do is write some assembler, with no copying between C/C++ variables and the CPU registers, you can simply give asm() one parameter that's a string of opcodes separated by newlines:

Code:
asm("cli\n nop\n nop\n nop\n sei\n");

This has been used about the place as a way of getting very short, accurate delays, as long as you know how many clock cycles the code will take to complete.  (Generally one cycle per instruction.)

To pass variables back and forth you must specify a list of input and output operands separated by ":".

The operands are referenced within the assembly code string using %0, %1, %2... (like parameters in shell script programming).

So in the code above the %0 gets mapped onto the variable a.

The "+r" bit is explained (not very clearly) in the Inline Assembler cookbook, part of the AVR libc docs, at http://www.nongnu.org/avr-libc/user-manual/inline_asm.html#io_ops

the 'r' is a 'constraint' (in this case representing 'any register') that goes along with the opcode mov, which is where the %0 is being used as an operand.  The '+' is a 'modifer' that in this case means 'read/write operand'.  

Each opcode has an associated set of constraints depending on what operands it can use, e.g. some opcodes only operate on registers.  There's a table listing opcodes and their constraints on the cookbook page.

15  Forum 2005-2010 (read only) / Syntax & Programs / Re: Embedding Assembly in C++ on: April 23, 2008, 06:19:55 pm
I've only just started looking into this myself today, but here are some resources I found.

(I can't really answer your question, I'm just doing a brain dump on stuff I located so far in the hope that it might help someone... it would be great to have a proper tutorial on this, or even some proper docs on how C/C++ and ASM relate to the "arduino language" and how you can switch between them once you're no longer a newbie.)

The first step is using the asm() function, which generates the code.

According to the FAQ, "All standard C and C++ constructs supported by avr-g++ should work in Arduino.", so first place to look seems to be avr-gcc docs:

avr-libc inline assembler cookbook
http://www.nongnu.org/avr-libc/user-manual/inline_asm.html

plus...

tutorials in assembler and interfacing (good)
http://www.avrbeginners.net/

more avr assembly tutorials
http://www.avr-asm-tutorial.net/avr_en/

AVR assembler user guide (overview and includes summary
of instructions and how many clock cycles they take)
http://www.atmel.com/atmel/acrobat/doc1022.pdf

AVR data book:
copy here: http://newit.gsu.unibel.by/resources/ (scroll to AVRTOC)

instruction set: http://newit.gsu.unibel.by/resources/CPUs%5CAtmel%5CDescribe%5CDATABOOK%5CCHAP05.PDF


So as an example you could replace the setup() of the canonical blink example with this and it will be equivalent:

Quote
void setup() {
  asm volatile(
   // DDRC = 0010 0000, ie. PORTB5 is OUT
    "ldi r16,48\n"
    "out 0x27,r16\n"
    );
}

Anyone who's well up on this stuff, I'd appreciate some light spreading on these two issues:

1. I have some very basic stuff working, but there seems to be disparity between the AVR assembly code I've found and the weird syntax used by avr-gcc.

2. The error messages generated during assembly appear in the IDE, but the .s files are deleted, so error msgs like those below are pretty useless since you can't work out what line they relate to in the source, or what the assembler is that was actually generated from the asm() call.  Is there a way of preventing the .s file from being deleted?


/var/tmp//ccKEd1bF.s: Assembler messages:

/var/tmp//ccKEd1bF.s:56: Error: constant value required


cheers

Pages: [1] 2 3 ... 6