Raised This Month: $240 Target: $400
 60% 

repair errors on pwn file


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
xred123
New Member
Join Date: Dec 2021
Old 12-05-2021 , 02:55   repair errors on pwn file
Reply With Quote #1

hello,
This is the code on pwn file with the errors messages after compilation on amx:
PHP Code:
/******************************************************************************
 * Copyright 2016-2017 Specialized Solutions LLC
 *
 * Title to the Materials (contents of this file) remain with Specialized
 * Solutions LLC.  The Materials are copyrighted and are protected by United
 * States copyright laws.  Copyright notices cannot be removed from the
 * Materials.
 *
 * See the file titled "Specialized Solutions LLC License Agreement.txt"
 * that has been distributed with this file for further licensing details.
 *
 * Default Badge Script for the small QCM badge
 *
 * This demo shows off many features of the PAWN language and the QCM
 * subsystem.
 *
 *****************************************************************************/

@timer4()
{
    
qcm_display_clear()
    
qcm_display_write_framebuffer()
}

@
can0_rx0(rx_msg[QCM_CAN_MSG])
{
    
rx_msg.id 0x001
    
    qcm_can_tx
(CAN0rx_msg)
    
    
qcm_display_write_text(020xF0xF0xF"RX0")
    
qcm_display_write_framebuffer()
    
qcm_timer_start(TIMER_4500false)
        
}

@
can1_rx0(rx_msg[QCM_CAN_MSG])
{
    
rx_msg.id 0x002
    
    qcm_can_tx
(CAN0rx_msg)
    
    
qcm_display_write_text(020xF0xF0xF"RX1")
    
qcm_display_write_framebuffer()
    
qcm_timer_start(TIMER_4500false)
        
}

@
can2_rx0(rx_msg[QCM_CAN_MSG])
{
    
rx_msg.id 0x003
    
    qcm_can_tx
(CAN0rx_msg)
    
    
qcm_display_write_text(020xF0xF0xF"RX2")
    
qcm_display_write_framebuffer()
    
qcm_timer_start(TIMER_4500false)
        
}

input_switch_bottom_debounce()
{
    
/* send normal CAN frame */

    
msg.id 0x555
    msg
.is_extended false
    msg
.is_fd false
    msg
.use_brs false
    msg
.dlc 8
    
    qcm_can_tx
(CAN0msg)
}

input_switch_top_debounce()
{
    
qcm_timer_stop(TIMER_4)
    
    
/* send FD CAN frame */
    
new msg[QCM_CAN_MSG]
    
    
msg.id 0x555
    msg
.is_extended false
    msg
.is_fd true
    msg
.use_brs true
    msg
.dlc 10
    
    qcm_can_tx
(CAN1msg)
    
}

@
gpio_input_switch_top()
{
    
/* start debounce timer */
    
qcm_timer_start(TIMER_2,50,false)
}    


@
gpio_input_switch_bottom()
{
    
/* start debounce timer */
    
qcm_timer_start(TIMER_3,50,false)
}

@
timer2()
{
    if (
qcm_gpio_get_input(GPIO_INPUT_SWITCH_TOP))
    {
        
/* button has been released - call new function to handle debounced input */
        
input_switch_top_debounce()
    }
}

@
timer3()
{
    if (
qcm_gpio_get_input(GPIO_INPUT_SWITCH_BOTTOM))
    {
        
/* button has been released - call new function to handle debounced input */
        
input_switch_bottom_debounce()
    }
}

main()
{
    
sleep 1000
    
    qcm_can_init
(CAN0500000true1000000)
    
qcm_can_init(CAN1500000true1000000)
    
qcm_can_init(CAN2500000true1000000)
    
    
qcm_can_configure_rx_handler(CAN0CAN_RX_HANDLER_00x555false)
    
qcm_can_configure_rx_handler(CAN1CAN_RX_HANDLER_00x555false)
    
qcm_can_configure_rx_handler(CAN2CAN_RX_HANDLER_00x555false)
    
    
qcm_gpio_configure_handler(GPIO_INPUT_SWITCH_TOPGPIO_EVENT_HIGH)
    
qcm_gpio_configure_handler(GPIO_INPUT_SWITCH_BOTTOMGPIO_EVENT_HIGH)
    
    

This is the errors messages:

C:\Users\jean marc houel\Documents\SDK\test\can_test.p(19) : warning 235: public function lacks forward declaration (symbol "@timer4")
C:\Users\jean marc houel\Documents\SDK\test\can_test.p(21) : error 017: undefined symbol "qcm_display_clear"
C:\Users\jean marc houel\Documents\SDK\test\can_test.p(22) : warning 217: loose indentation
C:\Users\jean marc houel\Documents\SDK\test\can_test.p(22) : error 017: undefined symbol "qcm_display_write_framebuffer"
C:\Users\jean marc houel\Documents\SDK\test\can_test.p(25) : warning 235: public function lacks forward declaration (symbol "@can0_rx0")
C:\Users\jean marc houel\Documents\SDK\test\can_test.p(25) : error 017: undefined symbol "QCM_CAN_MSG"
C:\Users\jean marc houel\Documents\SDK\test\can_test.p(27) : warning 215: expression has no effect
C:\Users\jean marc houel\Documents\SDK\test\can_test.p(27) : error 001: expected token: ";", but found "."
C:\Users\jean marc houel\Documents\SDK\test\can_test.p(27) : error 029: invalid expression, assumed zero
C:\Users\jean marc houel\Documents\SDK\test\can_test.p(27) : error 017: undefined symbol "id"
C:\Users\jean marc houel\Documents\SDK\test\can_test.p(27) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase


7 Errors.

Thank you.
Bye
xred123 is offline
JusTGo
Veteran Member
Join Date: Mar 2013
Location: Tunisia
Old 12-05-2021 , 03:25   Re: repair errors on pwn file
Reply With Quote #2

For which game is this?
__________________
JusTGo is offline
xred123
New Member
Join Date: Dec 2021
Old 12-05-2021 , 04:12   Re: repair errors on pwn file
Reply With Quote #3

it's for a car can_test module
xred123 is offline
DJEarthQuake
Veteran Member
Join Date: Jan 2014
Location: Astral planes
Old 12-05-2021 , 07:53   Re: repair errors on pwn file
Reply With Quote #4

Neat. How do you figure Amxx and that? Amxx has nothing to do with CAN. Where did you de-compile that from?
__________________
"It's not the actual programming that's interesting. But it's what you can accomplish with the end results that are important." -Dennis Ritchie
"Mathematics, rightly viewed, possesses not only truth, but supreme beauty a beauty cold and austere, like that of sculpture..." -Bertrand Russell
DJEarthQuake is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 12-05-2021 , 14:33   Re: repair errors on pwn file
Reply With Quote #5

This community is focused on writing plugins for video games that run either AMX Mod X or SourceMod (Half-Life-based games). While a version of the pawn programming language is used for these, this is probably not the best place for general Pawn programming that isn't for either AMX Mod X or SourceMod.
__________________
fysiks is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 00:28.


Powered by vBulletin®
Copyright ©2000 - 2022, vBulletin Solutions, Inc.
Theme made by Freecode