| |||||||
| Register | FAQ | Members List | Calendar | Arcade | Search | Today's Posts | Mark Forums Read |
| Programming and Assembly Language Please read this Topic's rules!! |
![]() |
| | LinkBack | Thread Tools | Rate Thread |
| ||||
| What exactly is your problem? You should be able to do anything in C++ that you can do in C.
__________________ Avatar and sig graphic by Pitch. Subscribers! Ask about a custom graphic or avatar today! Gizmo Thermal Diode Mod and Direct-Die Water Block 8-Cheetah 18GiB U-2 SCSI MegaRAID Enterprise 1500/128MiB Samsung SyncMaster 955DF TTGI/Superflower TTS-520 PSU ![]() ![]() ![]() |
| ||||
| Thats not the problem - i know C++ can use the serial port, its just that i havent got a clue how to! C++ is very new to me and i've no idea how to control the registers used in the UART using it, thats the problem...
__________________ Vapour Voltage Clock |
| ||||
| What OS? Any of the WinNT-derived OSen are not going to allow you to have direct access to the Serial port (or any other hardware for that matter) without some trickery. It has been several years since I've written anything to bit-bang the 16450/16550 UART. Since Allan seems to be more current, I'll let him tackle this. ![]() Allan, you're up.
__________________ Avatar and sig graphic by Pitch. Subscribers! Ask about a custom graphic or avatar today! Gizmo Thermal Diode Mod and Direct-Die Water Block 8-Cheetah 18GiB U-2 SCSI MegaRAID Enterprise 1500/128MiB Samsung SyncMaster 955DF TTGI/Superflower TTS-520 PSU ![]() ![]() ![]() |
| ||||
| The 'C' progs work fine on Win2000... ![]() If its any help i need to know how to control RTS, and DTR in the MCR, also how to check the LSR and read/write the base address in C++ Tom
__________________ Vapour Voltage Clock |
| ||||
| Quote:
However, in C++ I've only written a program that used HDLC via the RS232, but I have the C++ driver files for the UART we used. I could email them to you if you want? PM me with your email addy if you are interested. The comments are in Danish, but I can translate some of them if you want. Man, you gotta love assembly for stuff like this! Bit manipulation is just so much easier, me thinks. With this example, the amount of code lines isn't THAT much bigger with asm than with C++.. ![]() |
| ||||
| Assembly ROCKS! Even on the x86, which is about the most PITA assembly I know.
__________________ Avatar and sig graphic by Pitch. Subscribers! Ask about a custom graphic or avatar today! Gizmo Thermal Diode Mod and Direct-Die Water Block 8-Cheetah 18GiB U-2 SCSI MegaRAID Enterprise 1500/128MiB Samsung SyncMaster 955DF TTGI/Superflower TTS-520 PSU ![]() ![]() ![]() |
| ||||
| You have PM ![]() No problem, me too... I'd probably agree with you on the assembler thing, the only assembler ive done has been with PIC's, but for low level stuff like this i imagine it would be perfect! Unfortunately i have to use C++ ![]() Tom
__________________ Vapour Voltage Clock |
| ||||
| Still working on it... The API's used in C++ for the serial communication are identical to those used in Visual Basic, so for now im just writing the GUI in VB (i need to get something working for Thursday, so i thought it would be better to concentrate on an *easier* method of VB ). The C program for the slave PIC is complete, at the mo im making the interface board to connect it all together. The way ive got it working at the mo is: PC sends out request to slave PIC for either GPS, Compass or ADC - The slave PIC then relays the appropriate serial stream to the PC - The PC reads from serial buffer and displays it. Had a few problems with intefacing the rs232 outputs from the devices to the slave PIC since they use different baud rates (i was originaly going to use a small multiplexor), have that sorted now ![]() Its still going to be hectic tho... Thanks for the help ![]()
__________________ Vapour Voltage Clock |
| ||||
| Thanks - The final application will have to be written in C++ still (unless my project leader can be convinced otherwise!). The files you sent were very helpfull ![]() Will post a picture of the finished system when its done too.... Tom
__________________ Vapour Voltage Clock |
| ||||
| Hi, the attached shows the slave PIC board and the current (testing) GUI... its going to be "vero-boarded" and interfaced with the main board over the next few days... Have attached it as a .zip so as not to annoy anyone with slower connections and save your bandwidth... The picture of the board is low quality, i appologise in advance ![]() Tom
__________________ Vapour Voltage Clock |
| ||||
| Good luck vero-boarding it! Should make for a more permanent solution over the breadboard, eh? For some things I would prefer wire wrapping over soldering, mainly because my soldering skills aren't really up there. ![]() Thanks for the pictures!! |
| ||||
| Hi, got the whole system vero-boarded and running. Its got quite a few bugs still -but i'll get them sorted! ![]() The systems comprises of 2 x PIC18F452's and 2 x PIC16C84's - its becoming quite a monster! Got the GUI very nice now! Will post some pictures of the whole she-bang in the next few days when i can borrow a digital camera... Tom
__________________ Vapour Voltage Clock |