Hello Sid, How well is your asm? You have some digging to do.
The reason for incompatibility is that there is no common calling convention. First you'll have to find out what the options were they used for building the blestack library. Then you'll have to find out what that means in terms of passing parameters and receiving return values. If there is anything located in memory instead of on stack, you'll have to reserve that space from SDCC. Then you must create wrapper functions around the library functions that make the conversion without disturbing the stack. You can also try to find out who owns the blestack library. If it's TI's then they might be persuaded to also release it as an SDCC library. It's in their interest to sell IC's. But if it's IAR's who only gave this to TI to promote their own tools, then it's unlikely you can get it for SDCC. Good luck, Maarten > I am attempting to develop for the CC2540 device from Texas Instruments. It > has been noted the binary portions of their bluetooth stack that have been > released are not compatible with SDCC. What is the most likely reason for > such incompatibilities, and are they fixable with only object code? > > With the files found on > http://www.ti.com/tool/ble-stack?DCMP=wbu-blestack&HQS=blestack (warning: > .exe autoextracter; look in "Projects/ble/Libraries") I was hoping to be > able to pinpoint any discrepancies by perusing the disassembly of the > object files and attempt a manual or semi-manual fix. I simply don't know > what to look for. The CC2540 is a good enough offering I'm willing to bend > over backwards a little. > > Is this doable? What could possibly be different between IAR and SDCC code? > How hard would it be to, say, translate the object code/a raw disassembly > to a different memory model/whatever issue? > > Thanks for your time. > ------------------------------------------------------------------------------ Try New Relic Now & We'll Send You this Cool Shirt New Relic is the only SaaS-based application performance monitoring service that delivers powerful full stack analytics. Optimize and monitor your browser, app, & servers with just a few lines of code. Try New Relic and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_may _______________________________________________ Sdcc-user mailing list Sdcc-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sdcc-user