Search Results - MEL PICBASIC Forum


Search:

Type: Posts; User: tumbleweed; Keyword(s):

Page 1 of 4 1 2 3 4

Search: Search took 0.00 seconds.

  1. Replies
    9
    Views
    390

    Re: When Driving An Indicator L.E.D.

    Once you figure out how an LED works, then you can skip any additional circuitry you have driving the MOSFET relay LED input, and just treat it like a normal LED.
    All you need is a resistor in...
  2. Re: "Stretching" a byte variable into two byte variables?

    If you start off with B=0 and C=0 you can skip half those statements and only do the ones where A.x = 1
  3. Re: How to do bitwise shift across several variables/array members?

    Yes, assuming you really do want a shift and don't want to rotate the value shifted out of B back into the MSB of the array.
    There's no need to copy the array bytes to A and B, but if it helps you...
  4. Replies
    27
    Views
    1,983

    Re: Multiplying with 11 using PIC

    What do you mean by this?

    Do you want the pic to generate a square wave output from 11Hz to 11MHz on an output pin?
  5. new PIC CLCDesignerTool with simulator and PIC18F support

    For those with an aversion to MPLABX, or who just want a simple, easy to use standalone tool
    there is a new, updated version of the old CLCDesignerTool available.

    CLCDesignerTool V4 adds features...
  6. Replies
    3
    Views
    801

    Re: SEROUT loop with pause

    Completely unnecessary, just like it is with python on the PC.
  7. Replies
    4
    Views
    1,539

    Re: 16F1705 internal Opamp woes

    OPA1CON = %1100000 ' Opamp 1 Enabled, SP set.

    Isn't that missing a bit?
    Try


    OPA1CON = %11000000 ' Opamp 1 Enabled, SP set.


    For OPAMP1 you have
  8. Replies
    10
    Views
    4,350

    Re: Chip had no EE, should PBP3 know that?

    So, what's your definition of "many times", and when you say "I only use a few bytes" how many bytes is that?
  9. Re: understanding I2CWrite optional address parameter?

    The "address" is just another one or two data bytes (depending on the data type used) sent before the actual "data".
    Typically it's used for eeproms where you need to send an address parameter, or a...
  10. Re: getting my head around PICS with SR-Latch registers - and how to properly use the

    Yes. Write to the LAT register. Read from the PORT register.
  11. Re: HSEROUT of array of data with termination on a null

    Jimbo,

    The pic can transmit at that rate but you might run into trouble receiving.
    921K is only 10us/byte, so you'll have to be able to handle incoming data at that rate.

    I've run 460K baud...
  12. Re: HSEROUT of array of data with termination on a null

    That's probably not too bad, considering you have to send packet requests to get data.

    Doing that's a good idea... I was worried you were just going to stream 256MB out the pic and expect the PC...
  13. Re: HSEROUT of array of data with termination on a null

    Most PC serial ports will run at 230400 baud.
    The J53 will... just set:
    BRG16=1
    BRGH=0
    SPBRGH=0
    SPBRG=5

    That might shave it down to under 4 hrs.
    Make sure the MAX232 (or whatever you're...
  14. Replies
    10
    Views
    8,478

    Re: Erroneous mathematical processing?

    The K83 has its SFR registers located at the top of ram, and the common ones are in bank 63 ($3F00).

    The MOVFF instruction only uses 12-bits of addressing, so the highest address it can reach is...
  15. Re: HSEROUT of array of data with termination on a null

    At 115K it takes ~22ms to send 256 bytes assuming back to back transfers. At 9600 it's over 10x longer than that.

    You could use background serial transfers while you do something to read that...
  16. Re: HSEROUT of array of data with termination on a null

    richard's code has some merits, but in almost all cases interrupts just add overhead... they rarely speed things up if that's what you're looking for.

    Here's another version of the code I posted...
  17. Re: HSEROUT of array of data with termination on a null

    If you're looking for more efficient then drop the formatting entirely and just send the binary data.
    If you format 256MB of data using HEX2 you end up with twice the number of bytes to transfer...
  18. Replies
    15
    Views
    9,570

    Re: Hersin quick question

    TRISB=%00000001 'Make RB0 input


    For the 16F628A you're setting the RX input (RB1) to output mode.
    The datasheet says to set both bits TRISB.2 (RB2/TX) and TRISB.1 (RB1/RX).
  19. Re: 2 didit up down counter using 16F628A program errors

    The simplest form of the mpasm 'include' directive has the form:


    include p16f628a.inc

    I think the angle brackets made part of the line drop out in richard's post, so if you try to copy that...
  20. Replies
    19
    Views
    10,319

    Re: Unable to execute MPASMX

    Yes they do, but since it's only for the PIC18F series it's a little easier for them.

    I understand they'll be extending the existing MPASM to deal with new chips for a while, at least until mchip...
  21. Replies
    19
    Views
    10,319

    Re: Unable to execute MPASMX

    I don't think they give a ****.

    All of this was brought to their attention a while back and the response was basically "sucks to be you".
    It was "too hard" to convert mpasmx to 64-bit, and they...
  22. Replies
    19
    Views
    10,319

    Re: Unable to execute MPASMX

    Unfortunately there's more to it than just a name change.

    Assembly code written for MPASM will not work with pic-as (which is part of the XC8 V2.20 package), and has to be re-written to be...
  23. Replies
    19
    Views
    10,319

    Re: Unable to execute MPASMX

    Microchip have dropped MPASM/MPASMX as of MPLABX 5.40. It's no longer included.
    MPLABX is 64-bit only now, and MPASM is/was a 32-bit program.

    They have a new 8-bit assembler, pic-as.exe and it's...
  24. Replies
    27
    Views
    11,344

    Re: How to prevent variable going below zero?

    That's his problem... he DOES want to use a byte but as he adds or subtracts to the byte value it wraps and gives false operation.

    The way I usually handle this sort of thing is to have a routine...
  25. Replies
    27
    Views
    11,344

    Re: How to prevent variable going below zero?

    In your original code, change
    IF Z<100 THEN I=I-5 to this
    IF Z<100 AND I>=5 THEN I=I-5
Results 1 to 25 of 100
Page 1 of 4 1 2 3 4