fx2lib-devel Mailing List for fx2lib (Page 7)
Status: Beta
Brought to you by:
mulicheng
This list is closed, nobody may subscribe to it.
2008 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(1) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2009 |
Jan
(16) |
Feb
(2) |
Mar
(35) |
Apr
(4) |
May
(9) |
Jun
(5) |
Jul
(20) |
Aug
(2) |
Sep
(10) |
Oct
(14) |
Nov
(12) |
Dec
(11) |
2010 |
Jan
(8) |
Feb
|
Mar
|
Apr
|
May
(2) |
Jun
|
Jul
(6) |
Aug
(8) |
Sep
(4) |
Oct
|
Nov
|
Dec
|
2011 |
Jan
(4) |
Feb
(10) |
Mar
(25) |
Apr
|
May
|
Jun
(4) |
Jul
(11) |
Aug
(2) |
Sep
(11) |
Oct
|
Nov
|
Dec
|
2012 |
Jan
(1) |
Feb
|
Mar
|
Apr
(10) |
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2013 |
Jan
(2) |
Feb
|
Mar
|
Apr
|
May
(3) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2014 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(8) |
Sep
|
Oct
|
Nov
|
Dec
|
From: S S <ss...@ho...> - 2009-10-02 14:37:25
|
Hi Dennis, What sizes of .ihx and .iic files do you get using your bulkloop example? I get the following sizes: bulkloop.asm = 60kB bulkloop.rel = 24kB bulkloop.ihx = 21kB and the hex2bix firmware returns an error telling me the input image is too big for output file size Addr = 0x2000, len = 0xe The bulkloop example from cypress in comparison is around 2kB and it does not look too dissimilar to what you have done. Any idea on where I might have gone wrong? Incidentally what is the command you are using with sdcc for this example? Cheers, Sebastien _________________________________________________________________ Get the best of MSN on your mobile http://clk.atdmt.com/UKM/go/147991039/direct/01/ |
From: Nu T. <nu...@gm...> - 2009-10-01 06:19:10
|
Hello Chris, How perfect could this be? I also have a Digilent S3board. Thanks for this great resource! Best, -Nu On Thu, Oct 1, 2009 at 4:58 AM, Chris McClelland <ch...@ma...> wrote: > I made my own board for connecting an FX2LP to a Xilinx FPGA if you're > interested: http://www.makestuff.eu/wordpress/?page_id=446 > > The Eagle design files, some firmware and VHDL are there if you want > them. |
From: Nu T. <nu...@gm...> - 2009-10-01 06:11:36
|
Hello Maarten, Looks like Chris McClelland can solve my problem ( http://www.makestuff.eu/wordpress/?page_id=446 ). I happen to have the same FPGA board that he does. :-) Thanks for the pointer/info, though. Best, -Nu |
From: Nu T. <nu...@gm...> - 2009-10-01 06:04:24
|
Hello Dennis, Sorry for late reply. It was night time here in Thailand. > You'll most likely have to spin a custom PCB to hook an FPGA to the Cypress > devel board. I don't know of anyone that sells one. Perhaps someone else > on the list has done it. We also use Xilinx FPGAs and we spun our own board > with an FX2 and an FPGA. OpalKelly sells boards with an FX2/FPGA but they > don't support ISO endpoints and they don't give the source for their > firmware for you to customize. Looks like Chris McClelland's board can solve this problem. :-) > You can use any Keil/SDCC for any board with an FX2 part. As long as it is > an FX2 chip, you can always load your own firmware on the device. A word of > caution though, if you don't know the board schematic it can take quite a > while to get a custom firmware working on a device. Xilinx FPGAs for > instance have 4 or 5 different programming modes. You have to know which > pins are the mode pins that tell it which mode to program in, and then you > have to know which pins to send the data to the FPGA on. Thanks for the heads-up. I have the schematics for the FPGA board, so I don't think this will be a problem. > The Fx2 is great at streaming data from the FPGA to the PC. We are > currently doing it at 43 Mbps with the slave fifo interface. I've done it > up to about 33 Mbps with a GPIF. That is a great performance. Great work on the firmware! >> If you have more advice/pointer regarding whether I picked the right >> device to do USB interface, I would really appreciate it. > > I'm not an expert in alternatives but I'm sure there are other ways to do > it. The FX2 is a pretty common usb controller. I think many people that > don't use the FX2 probably use their own custom chip. FYI, other alternatives I have considered are: 1. OpenCores USB 2.0 function core at http://www.opencores.org/project,usb Pros: I just need a USB2.0 PHY<-->UTMI chip and feed the UTMI signal right into FPGA. Cheap hardware. Ultra-customizable. Cons: I suspect this core's Verilog is not yet fully verified. 2. Cypress CY7C68001 EZ-USB-SX2. This is almost the same as FX2, but without the 8051 microcontroller Pros: Avoid learning FX2's 8051 and interface directly to state machine in FPGA. The state machine can have ultra high performance. Cons: well, have to design a potentially very complex state machine in FPGA. Any limitation imposed by SX2 is still not solved. 3. Atmel AVR32 family Pro: Kitchen sink with powerful 32-bit RISC CPU interfacing with its built-in USB2.0 core. Cons: may be a total overkill for this project. Need to learn yet another platform. > The dev board provides most of the chips that the fx2 can directly utilize. > You don't necessarily need them on a custom PCB. You can store data in an > sram for instance, to give more memory to the FX2. I haven't actually used > this. My firmwares to date has all fit in the 16K FX2 ram. Thanks for this info. I hope my firmware can fit in 16k on board RAM as well. The problem does not look that complex. Best, -Nu |
From: Chris M. <ch...@ma...> - 2009-09-30 22:25:28
|
Hey Nu, I made my own board for connecting an FX2LP to a Xilinx FPGA if you're interested: http://www.makestuff.eu/wordpress/?page_id=446 The Eagle design files, some firmware and VHDL are there if you want them. - Chris On Wed, 2009-09-30 at 14:31 -0600, Dennis Muhlestein wrote: > Nu Tiu wrote: > > Hello Dennis, > > > > Thanks a lot for a very quick response. I have a couple more > > questions, and if you could help me, I'd really appreciate it. > > > > On Thu, Oct 1, 2009 at 2:19 AM, Dennis Muhlestein <de...@ub...> wrote: > > > >> Hi Nu, > >> > >> The only additional hardware you'll need is whatever peripheral device you > >> might wish to connect. > >> The Cypress dev kit has all the IO pins exposed and > >> comes with a bread-board adapter for plugging in your own stuff (albeit most > >> modern parts are too complex to use with their bread-board). Are you > >> planning on doing your experiments with only the FX2? > >> > > > > I will be connecting it with a Xilinx FPGA. > > > > You'll most likely have to spin a custom PCB to hook an FPGA to the > Cypress devel board. I don't know of anyone that sells one. Perhaps > someone else on the list has done it. We also use Xilinx FPGAs and we > spun our own board with an FX2 and an FPGA. OpalKelly sells boards with > an FX2/FPGA but they don't support ISO endpoints and they don't give the > source for their firmware for you to customize. > > > > >> The Cypress kit comes with a Keil compiler sample and only works on Windows. > >> That works for a bit, but you'll quickly run into their 4k firmware size > >> limit as you start putting logic into your firmware. You can use the fx2lib > >> library and SDCC for the compiler if you would rather stick to Open/Free > >> software. Fx2lib supports a good portion (if not all) of the library > >> features that Cypress provides for Keil. You can join the fx2lib mailing > >> list here if you like: > >> > >> http://sourceforge.net/mail/?group_id=247216 > >> > > > > I have signed up for the mailing list already. :-) > > > Great! I have copied the list on these last couple emails so perhaps > someone else that has done this might input if they like. > > > >> As a side note, there are other development boards on the market that are > >> cheaper than the Cypress dev kit. > >> > > > > Thanks. Just a bit deeper digging shows boards from > > http://www.acquiredevices.com/products.jsp > > They sell Cypress EZ-USB FX2 board for about US$70, which is more > > reasonable than Cypress's $400+. > > > > Would Cypress/Keil/SDCC tool work on alternative(cheaper) board? I > > mean, suppose I have Keil tools, can I write C code, compile, download > > it to Cypress and see it communicating back to Cypress software? > > > > You can use any Keil/SDCC for any board with an FX2 part. As long as it > is an FX2 chip, you can always load your own firmware on the device. A > word of caution though, if you don't know the board schematic it can > take quite a while to get a custom firmware working on a device. Xilinx > FPGAs for instance have 4 or 5 different programming modes. You have to > know which pins are the mode pins that tell it which mode to program in, > and then you have to know which pins to send the data to the FPGA on. > > > Here is what I plan to do for my project: > > 1. design a USB audio sound module which plays sound only (so data > > only flows out from host(PC) to USB device) > > 2. set up the cypress chip to be a USB audio class device using > > - isochronous audio data transfer from host > > - use asynchronous mode isochronous data transfer > > - program cypress to provide rate feedback for the isochronous data link > > 3. the data out from Cypress chip goes through FPGA which will perform > > digital filtering. > > 4. data from FPGA out will go through DAC and then to speakers/headphones. > > > > I hope cypress 68013a would be powerful enough to solve this problem. > > It doesn't look that hard, but although I know both C for software and > > Verilog for FPGA design, I am a newbie at embedded programming. > > > The Fx2 is great at streaming data from the FPGA to the PC. We are > currently doing it at 43 Mbps with the slave fifo interface. I've done > it up to about 33 Mbps with a GPIF. > > > If you have more advice/pointer regarding whether I picked the right > > device to do USB interface, I would really appreciate it. > > > I'm not an expert in alternatives but I'm sure there are other ways to > do it. The FX2 is a pretty common usb controller. I think many people > that don't use the FX2 probably use their own custom chip. > > A quick glance through Cypress's dev board shows that they provide > > access for the device pins and they have the following: > > > > - a PLD chip (GAL22LV10C) -- don't know what they program this thing > > for (but the code looks very simple) > > - an 128k - 8 bit SRAM (CY7C1019BV33) -- would this be necessary? > > - an RS232 transceiver -- i don't think I need it > > - some I2C IO expander -- i don't think i need it > > > > So, I just wonder in what scenario would I need an SRAM? > > > The dev board provides most of the chips that the fx2 can directly > utilize. You don't necessarily need them on a custom PCB. You can > store data in an sram for instance, to give more memory to the FX2. I > haven't actually used this. My firmwares to date has all fit in the 16K > FX2 ram. > > -Dennis > > > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry® Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9-12, 2009. Register now! > http://p.sf.net/sfu/devconf > _______________________________________________ > Fx2lib-devel mailing list > Fx2...@li... > https://lists.sourceforge.net/lists/listinfo/fx2lib-devel |
From: Maarten B. <sou...@ds...> - 2009-09-30 21:56:14
|
Hello, > > I will be connecting it with a Xilinx FPGA. > > You'll most likely have to spin a custom PCB to hook an FPGA to the > Cypress devel board. I don't know of anyone that sells one. Perhaps > someone else on the list has done it. We also use Xilinx FPGAs and we > spun our own board with an FX2 and an FPGA. OpalKelly sells boards with > an FX2/FPGA but they don't support ISO endpoints and they don't give the > source for their firmware for you to customize. I looked at those OpalKelly boards and the XEM3001 seems good enough for your application. It is indeed a pity they don't supply the schematics nor allow you to reprogram the FX2. But with a little effort I guess it should be possible to find the connections (since they aren't BGA or QFP) and circumvent the EEPROM at boot so you can reprogram it. > > Thanks. Just a bit deeper digging shows boards from > > http://www.acquiredevices.com/products.jsp > > They sell Cypress EZ-USB FX2 board for about US$70, which is more > > reasonable than Cypress's $400+. But they come without an FPGA which you still need to add. Greets, Maarten |
From: Dennis M. <de...@ub...> - 2009-09-30 20:31:59
|
Nu Tiu wrote: > Hello Dennis, > > Thanks a lot for a very quick response. I have a couple more > questions, and if you could help me, I'd really appreciate it. > > On Thu, Oct 1, 2009 at 2:19 AM, Dennis Muhlestein <de...@ub...> wrote: > >> Hi Nu, >> >> The only additional hardware you'll need is whatever peripheral device you >> might wish to connect. >> The Cypress dev kit has all the IO pins exposed and >> comes with a bread-board adapter for plugging in your own stuff (albeit most >> modern parts are too complex to use with their bread-board). Are you >> planning on doing your experiments with only the FX2? >> > > I will be connecting it with a Xilinx FPGA. > You'll most likely have to spin a custom PCB to hook an FPGA to the Cypress devel board. I don't know of anyone that sells one. Perhaps someone else on the list has done it. We also use Xilinx FPGAs and we spun our own board with an FX2 and an FPGA. OpalKelly sells boards with an FX2/FPGA but they don't support ISO endpoints and they don't give the source for their firmware for you to customize. > >> The Cypress kit comes with a Keil compiler sample and only works on Windows. >> That works for a bit, but you'll quickly run into their 4k firmware size >> limit as you start putting logic into your firmware. You can use the fx2lib >> library and SDCC for the compiler if you would rather stick to Open/Free >> software. Fx2lib supports a good portion (if not all) of the library >> features that Cypress provides for Keil. You can join the fx2lib mailing >> list here if you like: >> >> http://sourceforge.net/mail/?group_id=247216 >> > > I have signed up for the mailing list already. :-) > Great! I have copied the list on these last couple emails so perhaps someone else that has done this might input if they like. > >> As a side note, there are other development boards on the market that are >> cheaper than the Cypress dev kit. >> > > Thanks. Just a bit deeper digging shows boards from > http://www.acquiredevices.com/products.jsp > They sell Cypress EZ-USB FX2 board for about US$70, which is more > reasonable than Cypress's $400+. > > Would Cypress/Keil/SDCC tool work on alternative(cheaper) board? I > mean, suppose I have Keil tools, can I write C code, compile, download > it to Cypress and see it communicating back to Cypress software? > You can use any Keil/SDCC for any board with an FX2 part. As long as it is an FX2 chip, you can always load your own firmware on the device. A word of caution though, if you don't know the board schematic it can take quite a while to get a custom firmware working on a device. Xilinx FPGAs for instance have 4 or 5 different programming modes. You have to know which pins are the mode pins that tell it which mode to program in, and then you have to know which pins to send the data to the FPGA on. > Here is what I plan to do for my project: > 1. design a USB audio sound module which plays sound only (so data > only flows out from host(PC) to USB device) > 2. set up the cypress chip to be a USB audio class device using > - isochronous audio data transfer from host > - use asynchronous mode isochronous data transfer > - program cypress to provide rate feedback for the isochronous data link > 3. the data out from Cypress chip goes through FPGA which will perform > digital filtering. > 4. data from FPGA out will go through DAC and then to speakers/headphones. > > I hope cypress 68013a would be powerful enough to solve this problem. > It doesn't look that hard, but although I know both C for software and > Verilog for FPGA design, I am a newbie at embedded programming. > The Fx2 is great at streaming data from the FPGA to the PC. We are currently doing it at 43 Mbps with the slave fifo interface. I've done it up to about 33 Mbps with a GPIF. > If you have more advice/pointer regarding whether I picked the right > device to do USB interface, I would really appreciate it. > I'm not an expert in alternatives but I'm sure there are other ways to do it. The FX2 is a pretty common usb controller. I think many people that don't use the FX2 probably use their own custom chip. > A quick glance through Cypress's dev board shows that they provide > access for the device pins and they have the following: > > - a PLD chip (GAL22LV10C) -- don't know what they program this thing > for (but the code looks very simple) > - an 128k - 8 bit SRAM (CY7C1019BV33) -- would this be necessary? > - an RS232 transceiver -- i don't think I need it > - some I2C IO expander -- i don't think i need it > > So, I just wonder in what scenario would I need an SRAM? > The dev board provides most of the chips that the fx2 can directly utilize. You don't necessarily need them on a custom PCB. You can store data in an sram for instance, to give more memory to the FX2. I haven't actually used this. My firmwares to date has all fit in the 16K FX2 ram. -Dennis |
From: Dennis M. <de...@ub...> - 2009-09-30 19:19:56
|
Hi Nu, The only additional hardware you'll need is whatever peripheral device you might wish to connect. The Cypress dev kit has all the IO pins exposed and comes with a bread-board adapter for plugging in your own stuff (albeit most modern parts are too complex to use with their bread-board). Are you planning on doing your experiments with only the FX2? The Cypress kit comes with a Keil compiler sample and only works on Windows. That works for a bit, but you'll quickly run into their 4k firmware size limit as you start putting logic into your firmware. You can use the fx2lib library and SDCC for the compiler if you would rather stick to Open/Free software. Fx2lib supports a good portion (if not all) of the library features that Cypress provides for Keil. You can join the fx2lib mailing list here if you like: http://sourceforge.net/mail/?group_id=247216 As a side note, there are other development boards on the market that are cheaper than the Cypress dev kit. -Dennis apache wrote: > Nu Tiu <nu...@gm...> wrote: > Hello Dennis, > > I read with interest your experiment with Cypress cystream. I am interested in > developing a USB audio class device (isochronous asynchronous OUT streaming with > feedback) using 68013 part. > > I wonder what hardware is necessary to get all of this up and running. I > assume I need to have: > > 1. A computer with 8051 compiler running windows/linux > 2. A cypress CY3684 EZ-USB FX2LP Development Kit (which includes a board and > software) > > Please advise me if I need anything else on the hardware side. > > Your info/help regarding this matter will be greatly appreciated. > > Best, > -Nu > > Website: > IP: 124.120.144.167 > |
From: Dennis M. <de...@ub...> - 2009-09-24 16:15:24
|
Does anyone have a good idea of something useful to use the breakpoint output for? I found a firmware example where they set breakpoint h/l to the address of their main loop, then set BKPT to pulse. This would create a pulse high every time the loop function executed. Does anybody use this pin for anything important or is it more of a debug mechanism? -Dennis |
From: Dennis M. <de...@ub...> - 2009-09-21 15:45:52
|
Mark Brooks wrote: > Hi, > > I am using a Cyress EZ-USB FX2 chip. I have been using it in only > full-speed mode up to now, primarily since it is by default enumerated > that way at startup. The chip has the capability to run in "high-speed" > usb mode and the chips descriptor has been build with a "full-speed" and > "high-speed mode" (see below). > > My question is, how does one normally change to high speed mode in usb > devices. Is it in negotiation? Using libusb (0.1.12 verison) should I > change to another configuration using|:| > | int usb_set_configuration(usb_dev_handle *dev, int configuration);| > > > |My device descriptor in the USB chip looks something like this:| > |HighSpeedConfigDescr:: | > | .db 9 ; Descriptor length| > | .db TYPE_CONFIGURATION_DESCRIPTOR ; Descriptor type| > | .db (HighSpeedConfigDescrEnd-_HighSpeedConfigDescr) & 0xFF > ; Total Length (LSB)| > > > |_FullSpeedConfigDescr:: | > | .db 9 ; Descriptor length| > | .db TYPE_CONFIGURATION_DESCRIPTOR ; Descriptor type| > | .db (FullSpeedConfigDescrEnd-_FullSpeedConfigDescr) & 0xFF > ; Total Length (LSB)| > > |Anyone had any experience with this?| Hi Mark, Since you're showing assembly code for your device descriptor, I'm assuming you are developing your own firmware on the fx2. You might enjoy participating in the fx2lib mailing list [1]. Even if you don't use the library, we have some good information on fx2 firmware development now and then. As for your specific question, it takes a few things to get your device into high speed mode. 1) The device qualifier descriptor needs to be present to tell the system there is a usb2 descriptor available. 2) The OS reads the other speed descriptor and then sends the high speed interrupt. 3) you have to serve the full speed descriptor until you get the interrupt and then you start serving the high speed descriptor in response to the device config request. On a side note, fx2lib has routines that handle all this for you. (So does the Cypress/Keil firmware framework but fx2lib is written with SDCC and all LGPL). As for libusb, you don't have to do anything special. The library is used the same whether you are in full speed or high speed mode. -Dennis [1] http://sourceforge.net/mail/?group_id=247216 |
From: Dennis M. <de...@ub...> - 2009-09-18 16:29:49
|
I don't currently have any windows specific downloads, but the fx2lib code can be compiled with sdcc on windows. The utilities are written in Python, which can also be run on Windows. The only problem you'd have is the fx2 driver, which currently uses libusb-1.0, and there isn't a port of that on Windows. For my own projects, I use libusb-0.1 on windows. I'd like to provide a more robust windows interface for fx2lib but that is still slated for the future some time. You should, in the mean time, be able to use the cypress utilities on windows to load your firmware though. Most of the examples in fx2lib use printf for debugging. You can see the output of those statements if you have a serial console and attach to the sio-0 port on the dev board at 57600 baud. That is how I debugged and got most of fx2lib working correctly. Yuri wrote: > Maybe I made something wrong. Do you have a .exe for windows? > > ----- Original Message ----- From: "Dennis Muhlestein" > <de...@ub...> > To: "Yuri" <yur...@na...> > Sent: Friday, September 18, 2009 11:06 AM > Subject: Re: Allmybrain.com Question/Comment: EZ-USB FX2 > > >> I pushed changes to the source repository that affected eeprom >> writes. Can you check to make sure you're on the very latest git >> version. The eeprom requires writing single bytes at a time and you >> have to wait for it to be ready between each write (it's slow). >> Latest git version does this correctly. >> >> On Sep 18, 2009, at 7:02 AM, Yuri wrote: >> >>> Dennis, >>> >>> Thanks for the help. I found the program and tryed to upload my >>> firmware to EEPROm. Unfortunatelly when I do that, the program say >>> that wrote some bytes at EPROM, but then, the firmware don't change >>> (even after a restart). If I write in the RAM, the new firmware is >>> recognized. I tryed with my firmware and with the firmware that >>> came with the program. Do you have any idea about what to do to >>> sucefully change permanently my firmware? >>> >>> Thanks! Best regards >>> >>> Yuri >>> ----- Original Message ----- From: "Dennis Muhlestein" >>> <de...@ub... >>> > >>> To: "Yuri Sa Scaramussa" <yur...@na...> >>> Cc: "fx2lib developer mailing list" <fx2...@li... >>> > >>> Sent: Thursday, September 17, 2009 4:06 PM >>> Subject: Re: Allmybrain.com Question/Comment: EZ-USB FX2 >>> >>> >>>> Hi Yuri, >>>> >>>> Have you downloaded fx2lib? fx2lib has eeprom read/write functions >>>> that you can include in your firmware. In addition, there is an >>>> eeprom example that you can use to read/write firmware from the >>>> fx2 eeprom (if attached of course). There is also a script for >>>> converting the ihx files to compressed iic files (iic is the >>>> format used to store the firmware on the prom.) >>>> >>>> Here are some resources: >>>> >>>> Site: http://fx2lib.sf.net >>>> Mailing list: >>>> https://lists.sourceforge.net/lists/listinfo/fx2lib-devel >>>> (Good place to ask fx2/fx2lib specific questions, low traffic) >>>> Git source Repo: http://github.com/mulicheng/fx2lib/ >>>> (I recommend using the latest git version since I'm close to >>>> releasing 0.2 and Sourceforge version is at 0.1 still.) >>>> Blog topics I've written on the fx2: http://allmybrain.com/tag/fx2/ >>>> >>>> Best wishes, >>>> -Dennis >>>> >>>>> Yuri Sa Scaramussa <yur...@na...> wrote: >>>>> Hi Denis! I\\\'m using a device with EZ-USB fx2 and I\\\'m already >>>>> sucefully >>>>> uploaded a new firmware to the device\\\'s RAM, using >>>>> fx2_programmer. Now I\\\'m >>>>> trying to change the firmware permanently, but I\\\'m really not >>>>> finding a way. >>>>> Did you changed the firmware in EEPROM? What I have to do for >>>>> change it?</p><br >>>>> /> >>>>> <p>Thanks!!! >>>>> >>>> >>>> >>>> >>>> __________ Informao do ESET NOD32 Antivirus, verso da vacina 4433 >>>> (20090917) __________ >>>> >>>> A mensagem foi verificada pelo ESET NOD32 Antivirus. >>>> >>>> http://www.eset.com >>>> >>>> >>> >> >> >> >> __________ Informação do ESET NOD32 Antivirus, versão da vacina 4436 >> (20090918) __________ >> >> A mensagem foi verificada pelo ESET NOD32 Antivirus. >> >> http://www.eset.com >> >> >> > |
From: Dennis M. <de...@ub...> - 2009-09-17 20:06:08
|
Resurrecting old thread. I added these memory addresses to lights.h. You can enable them by defining FX1 before you include this header. example: SDCCFLAGS=-DFX1 make (assuming your make file adds the SDCCFLAGS to sdcc options). Anyway, there are a few other fx1/fx2 differences but this is a start to making the library work for both versions. Aric Marheine wrote: > These are the addresses for the lights on the CY3681 board: > > volatile xdata at 0x8000 BYTE D2ON; > volatile xdata at 0x8100 BYTE D2OFF; > volatile xdata at 0x9000 BYTE D3ON; > volatile xdata at 0x9100 BYTE D3OFF; > volatile xdata at 0xA000 BYTE D4ON; > volatile xdata at 0xA100 BYTE D4OFF; > volatile xdata at 0xB000 BYTE D5ON; > volatile xdata at 0xB100 BYTE D5OFF; > |
From: Dennis M. <de...@ub...> - 2009-09-17 19:06:45
|
Hi Yuri, Have you downloaded fx2lib? fx2lib has eeprom read/write functions that you can include in your firmware. In addition, there is an eeprom example that you can use to read/write firmware from the fx2 eeprom (if attached of course). There is also a script for converting the ihx files to compressed iic files (iic is the format used to store the firmware on the prom.) Here are some resources: Site: http://fx2lib.sf.net Mailing list: https://lists.sourceforge.net/lists/listinfo/fx2lib-devel (Good place to ask fx2/fx2lib specific questions, low traffic) Git source Repo: http://github.com/mulicheng/fx2lib/ (I recommend using the latest git version since I'm close to releasing 0.2 and Sourceforge version is at 0.1 still.) Blog topics I've written on the fx2: http://allmybrain.com/tag/fx2/ Best wishes, -Dennis > Yuri Sa Scaramussa <yur...@na...> wrote: > Hi Denis! I\\\'m using a device with EZ-USB fx2 and I\\\'m already sucefully > uploaded a new firmware to the device\\\'s RAM, using fx2_programmer. Now I\\\'m > trying to change the firmware permanently, but I\\\'m really not finding a way. > Did you changed the firmware in EEPROM? What I have to do for change it?</p><br > /> > <p>Thanks!!! > |
From: Dennis M. <de...@ub...> - 2009-09-04 17:24:05
|
Hi All, I've pushed a few minor updates to the fx2 repository. I'm getting ready to create an 0.2 release. You can see the 0.2 Changelog with the Github repository browser: http://tinyurl.com/lyeab2 The current git HEAD version is working quite well for me. We've released one firmware and have plans for enhancing our product for a wider audience. I hope others are having similar success with fx2lib/sdcc. Best wishes, Dennis |
From: Dennis M. <de...@ub...> - 2009-08-12 12:10:12
|
The example was out of date with API changes I made recently. I just pushed updated examples within the last couple days. You shouldn't see any compile problems after updating your repository. -Dennis On Aug 11, 2009, at 11:24 PM, bali asur wrote: > Hi: > > I have the latest git snapshot. I have tried compiling > bulkloop.c, but I get the following error. > > sling-slms[135]+ make > cp dscr_asm dscr.asm > asx8051 -logs dscr.asm > sdcc -mmcs51 --code-size 0x2000 --xram-loc 0x3000 -Wl"-b DSCR_AREA = > 0x2000" -Wl"-b INT2JT = 0x2200" -I../../include bulkloop.c dscr.rel > fx2.lib -L../../lib > bulkloop.c:219: error 102: too few parameters > make: *** [bulkloop.ihx] Error 1 > > Anybody else seeing this error? > > I am using sdcc version 2.9.0 > > Regards, > > bali > > ------------------------------------------------------------------------------ > Let Crystal Reports handle the reporting - Free Crystal Reports 2008 > 30-Day > trial. Simplify your report design, integration and deployment - and > focus on > what you do best, core application coding. Discover what's new with > Crystal Reports now. http://p.sf.net/sfu/bobj-july > _______________________________________________ > Fx2lib-devel mailing list > Fx2...@li... > https://lists.sourceforge.net/lists/listinfo/fx2lib-devel |
From: bali a. <bal...@gm...> - 2009-08-12 05:24:58
|
Hi: I have the latest git snapshot. I have tried compiling bulkloop.c, but I get the following error. sling-slms[135]+ make cp dscr_asm dscr.asm asx8051 -logs dscr.asm sdcc -mmcs51 --code-size 0x2000 --xram-loc 0x3000 -Wl"-b DSCR_AREA = 0x2000" -Wl"-b INT2JT = 0x2200" -I../../include bulkloop.c dscr.rel fx2.lib -L../../lib bulkloop.c:219: error 102: too few parameters make: *** [bulkloop.ihx] Error 1 Anybody else seeing this error? I am using sdcc version 2.9.0 Regards, bali |
From: Tim m. <tcm...@ya...> - 2009-07-30 19:04:23
|
Yes, agree 100% to bad these other parts don't come with high speed usb... The only ones I now of are high speed FX2, Atmel new Cortex and high end ARM parts. It is hard to find microcontrollers with high speed usb. ________________________________ From: Steve Calfee <nos...@ya...> To: fx2lib developer mailing list <fx2...@li...> Sent: Thursday, July 30, 2009 1:58:52 PM Subject: Re: [Fx2lib-devel] cheap fx2 hardware? Hi, Tim, Thanks for the info. I already have the ezusb/fx in the keyspan serial adapter for full speed stuff. The nice thing about the fx2 is its speed. I was able to keep up with a high speed/ high bandwidth iso stream which sends/receives 3 1024 byte packets in a microframe (24Mbyte per second iso). It also was able to transfer bulk at 45Mbytes/sec - limited by the host speed - it issued no NAKs. Also the downloadability of the ram based fx2 makes it a natural for a test type of device. Another nice feature is it can be forced into full speed, for even more flexibility in testing. Regards, Steve --- On Thu, 7/30/09, Tim michals <tcm...@ya...> wrote: >From: Tim michals > <tcm...@ya...> >Subject: Re: [Fx2lib-devel] cheap fx2 hardware? >To: "fx2lib developer mailing list" <fx2...@li...> >Date: Thursday, July 30, 2009, 11:32 AM > > > >These are AVR and PIC boards not fx2 but the AVR has more memory then the Cypress.. The only disadvantage is high speed USB. >... >AVR ($30) >http://www.pjrc.com/teensy/ >http://code.google.com/p/avropendous/ > >PIC($24) >http://www.sparkfun.com/commerce/product_info.php?products_id=762 > > > |
From: Steve C. <nos...@ya...> - 2009-07-30 18:59:01
|
Hi, Tim, Thanks for the info. I already have the ezusb/fx in the keyspan serial adapter for full speed stuff. The nice thing about the fx2 is its speed. I was able to keep up with a high speed/ high bandwidth iso stream which sends/receives 3 1024 byte packets in a microframe (24Mbyte per second iso). It also was able to transfer bulk at 45Mbytes/sec - limited by the host speed - it issued no NAKs. Also the downloadability of the ram based fx2 makes it a natural for a test type of device. Another nice feature is it can be forced into full speed, for even more flexibility in testing. Regards, Steve --- On Thu, 7/30/09, Tim michals <tcm...@ya...> wrote: From: Tim michals <tcm...@ya...> Subject: Re: [Fx2lib-devel] cheap fx2 hardware? To: "fx2lib developer mailing list" <fx2...@li...> Date: Thursday, July 30, 2009, 11:32 AM These are AVR and PIC boards not fx2 but the AVR has more memory then the Cypress.. The only disadvantage is high speed USB. ... AVR ($30) http://www.pjrc.com/teensy/ http://code.google.com/p/avropendous/ PIC($24) http://www.sparkfun.com/commerce/product_info.php?products_id=762 |
From: Tim m. <tcm...@ya...> - 2009-07-30 18:32:32
|
These are AVR and PIC boards not fx2 but the AVR has more memory then the Cypress.. The only disadvantage is high speed USB. ... AVR ($30) http://www.pjrc.com/teensy/ http://code.google.com/p/avropendous/ PIC($24) http://www.sparkfun.com/commerce/product_info.php?products_id=762 ----- Original Message ---- From: Steve Calfee <nos...@ya...> To: fx2...@li... Sent: Thursday, July 30, 2009 12:51:06 PM Subject: [Fx2lib-devel] cheap fx2 hardware? Hi all, I have done some work with fx and fx2 processors before with SDCC, and I would like to do so again. The problem is finding cheap hardware. I would like to do a usb test device for Linux host drivers, so low cost is important as others will have to buy the device to use the tests. With the ezusb/fx I got the keyspan usa-19 usb/serial dongle for $20. I used the Passmark usb loopback device before on a job (has some LEDs that can be controlled, see: $50 qty 1. See http://www.passmark.com/products/usb2loopback.htm I have found also this proto board for $57: http://www.acquiredevices.com/sermod56.jsp I found a few relatively cheap fx2/fpga boards, which ranged from about $90 to $300. The cheaper one seemed very interesting to experiment with, but the fpga it was using was quite old and probably obsolete. Does anyone else have any useful pointers for getting cheap hardware for prototype and software development? Thanks, Steve ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ Fx2lib-devel mailing list Fx2...@li... https://lists.sourceforge.net/lists/listinfo/fx2lib-devel |
From: Steve C. <nos...@ya...> - 2009-07-30 17:51:24
|
Hi all, I have done some work with fx and fx2 processors before with SDCC, and I would like to do so again. The problem is finding cheap hardware. I would like to do a usb test device for Linux host drivers, so low cost is important as others will have to buy the device to use the tests. With the ezusb/fx I got the keyspan usa-19 usb/serial dongle for $20. I used the Passmark usb loopback device before on a job (has some LEDs that can be controlled, see: $50 qty 1. See http://www.passmark.com/products/usb2loopback.htm I have found also this proto board for $57: http://www.acquiredevices.com/sermod56.jsp I found a few relatively cheap fx2/fpga boards, which ranged from about $90 to $300. The cheaper one seemed very interesting to experiment with, but the fpga it was using was quite old and probably obsolete. Does anyone else have any useful pointers for getting cheap hardware for prototype and software development? Thanks, Steve |
From: Dennis M. <de...@ub...> - 2009-07-28 18:58:27
|
>>> >> >> So they are at an ABSolute address and OVeRlayable by any other >> area. In >> what memory should the linker put it? XDATA? Or IDATA? Have you >> found in >> the asxxxx documentation that it defaults to CODE memory? And what >> do you >> think will happen if another area is put at the same address as this >> one? >> You've told the linker that this is OK. > > Perhaps I misunderstood the asx8051 docs. I thought ABS and CON were > mutually exclusive. I just re-read and found that it used to be that > way, but now is OK. I tried changing _INT2AV anD _INT4AV to (CODE, > ABS, CON) and it seems to have worked fine. Is that what you were > suggesting? > Just a side note. After trying this out a bit, There is something not working. I haven't narrowed it down yet but it appears that changing OVR to CON doesn't actually put the jump instructions in the correct location. i.e., my device doesn't operate properly w/ the change. I can however do (CODE,ABS,OVR) instead of just (ABS,OVR) and things work correctly. -Dennis |
From: Gerry R. <ge...@ro...> - 2009-07-28 18:26:07
|
Watching this conversation go by, guys, this is good meat and potatoes stuff. I've been pre-empted off of my 'play' subject for quite some time now, but I can see the light at the end of the tunnel again. I've got one ethernet driver to get functioning correctly with a mips32 build, and then my time pressures will slack off a bit, and I can once again head back to experimenting with the fx2 stuff. But, until then, I'll just quietly read anything coming thru here while I take a coffee break, I really cant allow the time diversion to go play right now. |
From: Dennis M. <de...@ub...> - 2009-07-28 17:50:24
|
On Jul 28, 2009, at 2:47 AM, Maarten Brock wrote: > Dennis, > >>> 2. usbjt.a51 has several areas defined without specifying the memory >>> type. >>> I advise to change them to (CODE, ABS, CON) so they will not end >>> up in >>> xdata by accident and the linker can check for overlaps. >> >> Which areas? _INT2AV,_INT4AV are ( ABS, OVR ) > > So they are at an ABSolute address and OVeRlayable by any other > area. In > what memory should the linker put it? XDATA? Or IDATA? Have you > found in > the asxxxx documentation that it defaults to CODE memory? And what > do you > think will happen if another area is put at the same address as this > one? > You've told the linker that this is OK. Perhaps I misunderstood the asx8051 docs. I thought ABS and CON were mutually exclusive. I just re-read and found that it used to be that way, but now is OK. I tried changing _INT2AV anD _INT4AV to (CODE, ABS, CON) and it seems to have worked fine. Is that what you were suggesting? > > P.S. You might want to change the "reply to" address, because my > mailer > wanted to reply to you personally instead of the mailing list. I think it tried to reply to me because I put your email address in the "to" field as well as the list email address. This email is just responding to the list. I think it'll work correctly. -Dennis |
From: Maarten B. <sou...@ds...> - 2009-07-28 08:47:48
|
Dennis, >> 2. usbjt.a51 has several areas defined without specifying the memory >> type. >> I advise to change them to (CODE, ABS, CON) so they will not end up in >> xdata by accident and the linker can check for overlaps. > > Which areas? _INT2AV,_INT4AV are ( ABS, OVR ) So they are at an ABSolute address and OVeRlayable by any other area. In what memory should the linker put it? XDATA? Or IDATA? Have you found in the asxxxx documentation that it defaults to CODE memory? And what do you think will happen if another area is put at the same address as this one? You've told the linker that this is OK. > For INT2JT, I specifically didn't put the .org in because it has to be > aligned on a page boundary and I didn't have a way to get the compiler > to put that in the correct location without telling the linker > specifically about it. By the way, INT2JT is declared as: > .area INT2J2 ( CODE ) > > I specify the INT2JT location in the firmware Makefile like this: > > sdcc -Wl"-b INT2JT 0x 0x3000" > > Is there a better way to do it? I think this is ok. >> Or if you want even more precise timing either fully write the >> function in >> asm or use a timer. > > I've struggled a little with the use of timers. Not how to use them, > but whether or not to use them. I like the idea of a better > resolution delay with timers but I don't like the idea of limiting the > usage of timers for other purposes. For instance, right now, the > serial code uses timer 2. If you want to use timer 2, you can't use > the serial code. Suppose I use timer 1 for a delay. Can you now not > use a timer for something else? > > Perhaps you have some suggestions on this subject. I know one > improvement would be to use the fx2 high speed baud generation timer > instead of timer 2. I don't think there are many other usages for > that timer than for serial IO. Using the baud generation timer will free the other timer for other uses. And since it is an fx2 lib I assume you don't need to worry about backward compatibility if the baud generator isn't there, right? For general not too fast timing I usually setup one millisecond timer and in its ISR set several signals to indicate one ms has passed. Then in the main loop round-robin task you check if the signal is set, clear it and react as needed. But beware this prevents using a blocking loop like the delay function is right now. Maarten P.S. You might want to change the "reply to" address, because my mailer wanted to reply to you personally instead of the mailing list. |
From: Dennis M. <de...@ub...> - 2009-07-27 22:32:02
|
On Jul 24, 2009, at 8:53 AM, Maarten Brock wrote: > 1. The generated documentation for fx2regs.h has put many descriptions > next to the wrong (next) registers. Good catch. I pushed an update for this. Eventually, I'd like to expand the documentation to include much more detailed information for each register but It hasn't been much of a priority since you can't do a lot without the TRM anyway and it's all in there already. > > 2. usbjt.a51 has several areas defined without specifying the memory > type. > I advise to change them to (CODE, ABS, CON) so they will not end up in > xdata by accident and the linker can check for overlaps. Which areas? _INT2AV,_INT4AV are ( ABS, OVR ) For INT2JT, I specifically didn't put the .org in because it has to be aligned on a page boundary and I didn't have a way to get the compiler to put that in the correct location without telling the linker specifically about it. By the way, INT2JT is declared as: .area INT2J2 ( CODE ) I specify the INT2JT location in the firmware Makefile like this: sdcc -Wl"-b INT2JT 0x 0x3000" Is there a better way to do it? > > 3. The value in loop_count in delay.c seems wrong. And if you don't > like > volatile in delay.c then I suggest the use of NOP's and also use > only 8 > bit counters. This way the chosen model has little influence. E.g. I had planned on revisiting this function actually. I like your suggestions. > > void delay(WORD millis) > { > register BYTE count_inner, count_outer; > > do { > count_outer = 3; > do { > count_inner = 250; > do { > #if (CPUFREQ == CLK_12M) > NOP(); // 1 cycle > #elif (CPUFREQ == CLK_24M) > NOP(); // 5 cycles > NOP(); > NOP(); > NOP(); > NOP(); > #else > NOP(); // 13 cycles > NOP(); > NOP(); > NOP(); > NOP(); > NOP(); > NOP(); > NOP(); > NOP(); > NOP(); > NOP(); > NOP(); > NOP(); > #endif > } while (--count_inner); //should result in DJNZ Rn : 3 cycles > } while (--count_outer); //should result in DJNZ Rn > } while (--millis); > } > > Or if you want even more precise timing either fully write the > function in > asm or use a timer. I've struggled a little with the use of timers. Not how to use them, but whether or not to use them. I like the idea of a better resolution delay with timers but I don't like the idea of limiting the usage of timers for other purposes. For instance, right now, the serial code uses timer 2. If you want to use timer 2, you can't use the serial code. Suppose I use timer 1 for a delay. Can you now not use a timer for something else? Perhaps you have some suggestions on this subject. I know one improvement would be to use the fx2 high speed baud generation timer instead of timer 2. I don't think there are many other usages for that timer than for serial IO. > > 4. The functions in eputils.c could be sped up if you use the > autoptr's. > And even more if you unroll the inner loop for the special case of 64 > bytes. In general, the whole library needs a passthrough for performance. I'm kind of at the functionality stage, making sure things work. I'd also like to do some optimization for size at some point. Thanks for your suggestions. Dennis |