I am trying to get some USB-device functionality in a MCF5329 based board, and I am finding some trouble when trying to get the device initialised.
I cannot change the value of some registers like USB Mode Register (0xFC0B_01A8). When the system is started their value is 0x0000_0000 and it stays that way whatever I do.
I've tried the following pieces of code, and the result is the same:
- Code automatically generated by the Beans in CodeWarrior 7.0
- Code automatically generated by CodeWarrior 6.2 ==> Hello World Application, with a line of code trying to change the value of USB Mode Register
- Code from MCF532XSC usb_dev_mouse downloaded from:
http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=MCF532X&nodeId=0162468rH3YTLC00M92076...
I am quite certain that it is not a problem with the debugger interface of CodeWarrior because if I output the value of the register through the serial line I get the same result: 0x0000_0000 .
I've also performed another two alternative tests that I know that wouldn’t be valid in a final design, but I have once again failed to change the value of those registers:
- I’ve added this line to the .cfg file used by CodeWarrior for initialising the microcontroller:
Code:
writemem.l 0xFC0B_01A8 0x00000006
-I’ve tried to alter the value stored in the register with the memory window from CodeWarrior’s debugger after including this line in the .mem file:
Code:
range 0xFC000000 0xFFFFFFFF 4 ReadWrite
I don’t know what else I can do to get this solved. ¿Does anybody know what I am doing wrong? Any help will be highly appreciated. If you need any code or further explanation, please don’t hesitate to ask.
Thanks in advance for your time and help.