One-ticket round-trip method and one-ticket round-trip system for rail transit

By generating round-trip tickets in the form of QR codes, the problem of high operating costs in rail transit is solved, enabling one ticket to be used twice, improving the efficiency of entering and exiting stations and ticketing security, and adapting to the needs of fixed-section travel.

CN121640588APending Publication Date: 2026-03-10PCI TECH & SERVICE CO LTD +4
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-04
Publication Date
2026-03-10

AI Technical Summary

Technical Problem

Traditional rail transit physical single-journey tickets have high operating costs and complex equipment maintenance. Furthermore, with the widespread adoption of internet ticketing, it is inconvenient for passengers to purchase tickets, resulting in low usage efficiency.

Method used

This paper proposes a method for one-ticket round-trip transportation, which generates a round-trip ticket in the form of a QR code, allowing passengers to complete the round-trip journey with a single ticket purchase. The ticket is verified and its status is managed through an online ticketing system, replacing the traditional two-ticket process.

Benefits of technology

It reduces passenger queuing time, lowers operating costs, improves station entry and exit efficiency, ensures ticketing data security, and is suitable for fixed-distance travel scenarios such as business commuting and tourism.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121640588A_ABST
    Figure CN121640588A_ABST
Patent Text Reader

Abstract

The invention discloses a one-ticket round-trip method and a one-ticket round-trip system for rail transit. The one-ticket round-trip method for the rail transit comprises the following steps: in response to a ticket buying request of a passenger, acquiring ticket buying information of the passenger to generate a return ticket; and in response to the condition that the return ticket is identified at the gate terminal of the station and the return ticket passes verification, starting the gate terminal of the station, and modifying the state of the return ticket according to the position of the station and the type of the gate terminal. Through the mode, the operation cost of a round trip scene in rail transit can be reduced, and the user satisfaction degree is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of rail transit, and in particular to a method and system for one-ticket round trip in rail transit. Background Technology

[0002] Traditional physical single-journey tickets require processes such as ticket production, warehousing, transportation, and collection, involving a large amount of manpower and material resources, which increases the operating costs of rail transit companies. Furthermore, the need for gate collection at the exit further increases the complexity of equipment maintenance and ticket processing. Physical single-journey tickets rely on automatic ticket vending machines for issuance, which have high equipment maintenance costs. Moreover, with the popularization of online ticketing, the number of physical single-journey tickets is gradually decreasing, causing inconvenience for passengers to purchase tickets, further reducing the efficiency of use, and generating significant operating costs for rail transit. Summary of the Invention

[0003] This application provides a single-ticket round-trip method and system for rail transit to address the high operating costs of round-trip journeys in rail transit.

[0004] To solve the above-mentioned technical problems, one technical solution adopted in this application is: to provide a one-ticket round-trip method for rail transit, including: in response to a passenger's ticket purchase request, obtaining the passenger's ticket purchase information to generate a round-trip ticket; in response to the round-trip ticket being recognized at a station's gate terminal and the round-trip ticket passing verification, opening the station's gate terminal, and modifying the status of the round-trip ticket according to the location of the station and the type of the gate terminal.

[0005] In some embodiments, the ticketing information includes a travel itinerary; obtaining the passenger's ticketing information to generate a round-trip ticket includes: verifying whether the current rail transit configuration supports the travel itinerary; generating QR code data for the round-trip ticket based on the verified ticketing information; and generating the round-trip ticket based on the QR code data.

[0006] In some embodiments, generating the QR code data of the round-trip ticket based on the verified ticket purchase information includes: configuring corresponding code data information according to the ticket purchase information; assembling the code data information to generate code structure data; and adding a signature to the code structure data to save it as the QR code data.

[0007] In some embodiments, adding a signature to the code structure data includes: encrypting the code structure data using an asymmetric encryption algorithm and generating a public-private key pair for the asymmetric encryption algorithm; adding the signature to the end of the code structure data using the encrypted private key; and sending the public key to a ticketing terminal, wherein the public key is used to verify the consistency of the signature.

[0008] In some embodiments, the verification method for the round-trip ticket includes: verifying the legality of the code structure data corresponding to the round-trip ticket; in response to the code structure data passing the legality verification, verifying the usage status of the code structure data; and in response to the code structure data passing the usage status verification, verifying whether the station to which the device code of the code structure data belongs is consistent with the ticket-selling station of the round-trip ticket.

[0009] In some embodiments, the legality verification of the code structure data corresponding to the round-trip ticket includes: verifying the consistency of the issuing agency code of the round-trip ticket, verifying the timeliness of the round-trip ticket, verifying the device coding support status of the gate terminal, and verifying the consistency of the signature.

[0010] In some embodiments, the ticket purchase information further includes ticket purchase terminal information; obtaining the passenger's ticket purchase information to generate a round-trip ticket further includes: printing the round-trip ticket on paper if the passenger's ticket purchase terminal is an automatic ticket vending machine; or generating the round-trip ticket in electronic image form if the passenger's ticket purchase terminal is a mobile ticketing program.

[0011] In some embodiments, before obtaining the passenger's ticket purchase information to generate a round-trip ticket, the method further includes: obtaining the ticket cover, ticket font, and ticket style of the ticketing station to set the ticket customization data of the ticketing station; and updating the customized ticket face of the round-trip ticket according to the ticket customization data.

[0012] In some embodiments, the step of responding to the round-trip ticket being recognized at a station's gate terminal and the round-trip ticket passing verification, opening the station's gate terminal, and modifying the status of the round-trip ticket according to the station's location and the gate terminal's type includes: responding to the round-trip ticket being recognized at a ticket-selling station's entry terminal and the round-trip ticket passing verification, opening the ticket-selling station's exit terminal and modifying the round-trip ticket's status to outbound entry; responding to the round-trip ticket being recognized at a destination station's exit terminal and the round-trip ticket passing verification, opening the destination station's exit terminal and modifying the round-trip ticket's status to outbound exit; responding to the round-trip ticket being recognized at a destination station's entry terminal and the round-trip ticket passing verification, opening the destination station's entry terminal and modifying the round-trip ticket's status to return entry; and responding to the round-trip ticket being recognized at an exit terminal and the round-trip ticket passing verification, opening the exit terminal and modifying the round-trip ticket's status to invalid.

[0013] To solve the above-mentioned technical problems, another technical solution adopted in this application is: providing a round-trip ticket system for rail transit, comprising: a ticketing terminal, the ticketing terminal including an automatic ticket vending machine and a mobile ticketing program, the automatic ticket vending machine being set in the non-paid area of ​​the station for selling and printing paper round-trip tickets, the mobile ticketing program being set in a mobile communication device for selling and generating electronic round-trip tickets; a turnstile terminal, the turnstile terminal including an entry terminal and an exit terminal, the entry terminal being used to verify the round-trip ticket to complete the passenger's entry, the exit terminal being used to verify the round-trip ticket to complete the passenger's exit; and a ticketing system, the ticketing system connecting the ticketing terminal and the turnstile terminal through an Internet device gateway, the ticketing terminal and the turnstile terminal sending information to the ticketing system through a socket channel to complete the round-trip ticket method as described above.

[0014] The beneficial effects of this application are as follows: Unlike existing technologies, this application discloses a one-ticket round-trip method and system for rail transit. By responding to a passenger's ticket purchase request, the system obtains the passenger's ticket information to generate a round-trip ticket; replacing the traditional process of issuing two single-journey tickets, eliminating the need for passengers to purchase single-journey tickets twice, allowing for a single operation to complete the round-trip ticketing process, reducing queuing time at high-traffic stations, and better suited for fixed-distance travel scenarios such as business commuting and tourism. Upon the round-trip ticket being recognized at the station's turnstile terminal and passing verification, the turnstile terminal is opened, and its status is modified according to the station's location and the type of turnstile terminal; QR code verification is performed through the internet ticketing system during entry and exit, effectively preventing counterfeiting and tampering with tickets, ensuring ticket data security; the system records the passenger's journey origin through status markers, providing a data foundation for subsequent exit and return processes, ensuring the system accurately tracks the entire lifecycle of a single round trip. Furthermore, after completing the outbound journey, the system allows passengers to initiate a return journey at the target station without needing to purchase a new ticket, realizing the core function of one ticket for two uses. Tickets should be promptly invalidated after use to prevent overdue or reused tickets and ensure the safety of rail transit company revenue. Invalidated round-trip tickets do not need to be collected by turnstiles and passengers can keep them themselves, reducing the traditional physical ticket collection, counting and secondary processing procedures and further reducing operating costs. Attached Figure Description

[0015] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort, wherein: Figure 1 This is a flowchart illustrating an embodiment of the one-ticket round-trip method for rail transit provided in this application; Figure 2 Is it like this? Figure 1 The flowchart of one embodiment of method step 1000 is shown; Figure 3 Is it like this? Figure 2 The flowchart of step 1200 of the method shown is a schematic diagram of an embodiment; Figure 4 Is it like this? Figure 3 The flowchart of step 1230 of the method shown is a schematic diagram of an embodiment; Figure 5 Is it like this? Figure 1 A flowchart illustrating another embodiment of the method shown; Figure 6 Is it like this? Figure 1 The flowchart of one embodiment of method step 2000 is shown; Figure 7 Is it like this? Figure 1 A flowchart illustrating another embodiment of method step 2000 is shown. Figure 8 This is a schematic diagram of an embodiment of a single-ticket round-trip system for rail transit provided in this application. Detailed Implementation

[0016] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of the embodiments. Based on the embodiments of this application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of this application.

[0017] The terms "first," "second," and "third" used in the embodiments of this application are for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, a feature defined as "first," "second," or "third" may explicitly or implicitly include at least one of that feature. In the description of this application, "multiple" means at least two, such as two, three, etc., unless otherwise explicitly specified. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units not listed, or may optionally include other steps or units inherent to these processes, methods, products, or devices.

[0018] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a mutually exclusive, independent, or alternative embodiment. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.

[0019] See Figure 1 , Figure 1 This is a flowchart illustrating an embodiment of a one-ticket round-trip method for rail transit provided in this application. The one-ticket round-trip method for rail transit includes the following steps: 1000: In response to a passenger's ticket purchase request, obtain the passenger's ticket purchase information to generate a round-trip ticket.

[0020] In the non-paid area, passengers access the round-trip ticket sales interface, select their destination station, quantity, and payment method, and complete the payment. The ticketing terminal then sends a code request to the online ticketing system. The system returns the encrypted code data to the terminal, which then issues the ticket. Passengers can then use the round-trip ticket to enter and exit the station.

[0021] A ticket purchase request is an instruction initiated by a passenger through a ticket vending machine (TVM) or mobile app to purchase a round-trip ticket for rail transit. Passengers need to enter the round-trip ticket sales interface, select the destination station, quantity, payment method, etc., and after completing the payment, the system will trigger the request process to generate the round-trip ticket.

[0022] Ticketing information is crucial data submitted by passengers during the ticket purchase process, including the destination station for the round trip, the number of tickets available, and the payment method. This information is the core basis for the online ticketing system to generate round-trip tickets and needs to be uploaded to the system for verification and processing via terminal devices.

[0023] A round-trip ticket is a return ticket that can be used for two trips within the rail transit system. It is a paper QR code ticket that replaces the traditional two single-journey tickets. It includes the right to travel back and forth between the ticket purchase station and the destination station, and then back from the destination station to the ticket purchase station. It is valid for the current operating day, does not need to be collected when passing through the gate, and supports ticket customization.

[0024] It replaces the process of purchasing two single-journey tickets, reducing passenger queuing time and maintenance costs of automatic ticket vending machines; it also eliminates the need for ticket collection, saving on ticket production, warehousing, transportation, and collection processes, thus reducing the operating costs of rail transit companies.

[0025] Optionally, the ticket information may include the itinerary.

[0026] See Figure 2To obtain passengers' ticketing information and generate round-trip tickets, the process further includes the following steps: 1100: Verify whether the current rail transit configuration supports the trip.

[0027] After passengers submit their ticket purchase information at the automatic ticket vending machine or mobile app, select their destination station and payment method, and complete the payment, the terminal device sends a code generation request to the online ticketing system. The system verifies the following based on the rail transit configuration: whether the passenger's selected ticket purchase station, destination station, and round-trip station are within the preset available ticket range; whether the ticket purchase was completed in a non-paid area; and whether the current trip conforms to the special operating scenario configuration. If the configuration supports the trip, proceed to the next step; otherwise, the system refuses to generate a round-trip ticket and displays an error message.

[0028] The configuration of rail transit tickets is based on pre-set ticketing rules and parameters in the rail transit operation backend, including the range of stations available for sale, sales area restrictions, and operational scenario parameters, such as special line configurations for airport express lines and temporary event tickets. For example, the system can be flexibly configured to allow the purchase of round-trip tickets from this station to station A and from station B to this station, while prohibiting the purchase of tickets from other stations to this station, in order to adapt to different operational needs.

[0029] A journey is a passenger's planned round-trip rail travel route, specifically two consecutive journeys: outbound: ticket purchase station → destination station and return: destination station → ticket purchase station. For example, if a passenger purchases a round-trip ticket from Guangzhou East Railway Station to Tiyu Xilu Station, the journey includes two travel rights: Guangzhou East Railway Station → Tiyu Xilu Station and return: Tiyu Xilu Station → Guangzhou East Railway Station.

[0030] By verifying whether the rail transit configuration supports the trip, we ensure that only round-trip tickets that comply with the backend rules are issued, thus avoiding invalid ticket purchases or illegal ticketing operations and reducing the cost of manual intervention.

[0031] 1200: Generates QR code data for round-trip tickets based on verified ticket purchase information.

[0032] The system extracts the outbound origin station code, return destination station code, fare amount, QR code validity period, equipment code, etc.; and generates complete QR code data according to the paper QR code RJT code structure field table.

[0033] The QR code data is structured encrypted data that stores key information about round-trip tickets. It includes fields such as origin and destination station codes, ticket price, validity period, device code, and encrypted signature. It can be encrypted using the SM2 national cryptographic algorithm and a verification signature can be attached for gate recognition and ticket legality verification.

[0034] Structured QR code data can be quickly recognized by turnstiles, which can then verify the data to enable automatic passage and improve entry and exit efficiency.

[0035] Further, see Figure 3 Step 1200 further includes the following steps: 1210: Configure the corresponding code data information based on the ticket purchase information.

[0036] Based on the ticket purchase information submitted by the passenger, the online ticketing system dynamically fills in the values ​​of each field of the code data information.

[0037] Specifically, the relevant information for each field value is shown in the table below:

[0038]

[0039] In the table, B indicates that the field is binary data, Ans indicates that the field contains alphanumeric characters and special characters; M indicates that the field must exist, MC indicates that the field is required, and C indicates that the field is not required.

[0040] The QR code data is dynamically configured based on the ticket purchase information, so that the QR code contains unique trip permissions, ensuring that passengers can only use the corresponding trip and avoid taking the bus beyond the scope. At the same time, the station, fare and other information printed on the ticket are intuitive and transparent, which enhances passenger trust.

[0041] 1220: Assemble code data information to generate code structure data.

[0042] The configured code data information is structured and integrated according to the field order, length, and format of the paper QR code RJT code structure table.

[0043] For example, arrange the fields in sequence from 1 to 25, ensuring that field 1 "QR code version" is 1 byte and field 3 "Issuing institution public key certificate" is 288 bytes, etc.; perform integrity checks on "required fields", such as field 2 "QR code data length" and field 19 "ticket order number", and fill in non-required fields, such as field 16 "device code" according to the actual situation.

[0044] Code structure data is a structured data set assembled from code data information according to a preset format, forming a standardized data structure that can be parsed by the gate. This standardized code structure data, containing all key ticketing information, prepares for subsequent encrypted signatures.

[0045] By standardizing and assembling the code structure data to fix the field order, length, and format, it ensures that terminal equipment such as turnstiles can efficiently parse QR code information, avoid gate failures caused by chaotic data formats, and improve ticket checking efficiency.

[0046] 1230: Add a signature to the code structure data to save it as QR code data.

[0047] The internet ticketing system uses a pre-generated private key to encrypt the code structure data, generating field 23 "Issuing Institution Authorization Signature" and field 25 "Payment Account User Private Key Signature", which are appended to the end of the code structure data; the complete code structure data containing the signature is converted into QR code image data, supporting terminal devices to print paper tickets or display electronic tickets.

[0048] A signature is a verification message generated by encrypting code structure data, including the issuing institution's authorization signature and the payment account user's private key signature. The internet ticketing system uses its private key to encrypt the code structure data and generate a signature, which is appended to the end of the code structure; the gate verifies the signature's consistency using its public key to confirm that the data has not been tampered with or forged.

[0049] Further, see Figure 4 Step 1230 further includes the following steps: 1231: Encrypt code structure data using an asymmetric encryption algorithm and generate a public-private key pair for the asymmetric encryption algorithm.

[0050] The online ticketing system pre-generates a public-private key pair for an asymmetric encryption algorithm. The private key is encrypted and stored in the system backend, while the public key is used for backup and distribution. The assembled code structure data is encrypted to ensure that the data is not illegally read during transmission and storage.

[0051] Optionally, the asymmetric encryption algorithm is the SM2 national cryptographic algorithm.

[0052] Asymmetric encryption algorithms are cryptographic algorithms that use a pair of keys for encryption and decryption. The public key can be publicly distributed, while the private key must be kept secret. This embodiment uses the SM2 national cryptographic algorithm to encrypt code structure data and generate signatures, ensuring the security of data transmission and storage.

[0053] The process involves decrypting and verifying the signature at the end of the code structure data using the public key to confirm that the signature completely matches the original signature generated by the system using the private key. If they match, it indicates that the code structure data has not been tampered with or forged; if they do not match, the ticket is deemed invalid.

[0054] By using asymmetric encryption algorithms such as SM2 and public-private key signature mechanisms, it is ensured that the code structure data cannot be illegally tampered with or forged during the generation, transmission and use of the data, effectively avoiding operational revenue losses caused by counterfeit tickets or ticket alterations.

[0055] 1232: Add a signature to the end of the code structure data using the encrypted private key.

[0056] The system uses the private key stored in the background to digitally sign the encrypted code structure data, generating an authorization signature from the card issuer and a private key signature from the payment account user; the generated signature information is appended to the end of the code structure data to form complete encrypted data containing the original data and the signature.

[0057] 1233: Send the public key to the ticketing terminal. The public key is used to verify the consistency of the signature.

[0058] The internet ticketing system distributes pre-generated public keys to all ticketing terminals, and the terminal devices store the public keys for backup. When a passenger passes through the gate with a ticket, the terminal device uses the public key to decrypt the signature at the end of the cryptographic structure data and verifies whether it matches the signature generated by the system using the private key. If it matches, the ticket is deemed valid.

[0059] The ticketing terminal automatically verifies signature consistency using a public key, quickly determining ticket legitimacy without manual intervention. This reduces queuing time caused by manual verification and improves entry and exit efficiency. The private key is encrypted and stored in the system backend, while the public key is distributed to the terminals in a distributed manner, forming an architecture that combines centralized signature with distributed verification. Even if some terminal devices are attacked, the private key remains secure and controllable, ensuring the overall ticketing system's resilience and adapting to the large-scale, high-concurrency operation scenarios of urban rail transit.

[0060] 1300: Generate round-trip tickets based on QR code data.

[0061] The online ticketing system returns the generated QR code data to the terminal device used by the passenger to purchase the ticket. After receiving the QR code data, the automatic ticket vending machine prints a paper round-trip ticket containing the QR code image and key information; or after receiving the QR code data on a mobile app, it displays the QR code electronically, with the same appearance and usage attributes as the paper ticket.

[0062] QR code data is structured data that contains key information about the round trip and is encrypted and signed.

[0063] Optionally, the ticketing information may also include ticketing terminal information.

[0064] Obtaining passenger ticketing information to generate round-trip tickets also includes: The ticketing terminals for passengers are automatic ticket vending machines that print round-trip tickets on paper.

[0065] The system responds to the terminal type and prints paper round-trip tickets containing QR code images and key information such as ticket price, release time, origin / destination station, etc., through the printing module of the automatic ticket vending machine.

[0066] Alternatively, in response to the passenger's ticketing terminal being a mobile ticketing program, round-trip tickets can be generated in the form of electronic images.

[0067] The system responds to the terminal type and generates a round-trip ticket QR code image in the form of an electronic image within the mobile APP. Passengers can directly view, screenshot, save, or display the ticket within the APP. Its appearance and usage attributes are consistent with the paper ticket.

[0068] Supporting both automatic ticket vending machines and mobile apps, the system caters to different passenger needs: passengers without smartphones or who prefer physical tickets can obtain paper tickets from the automatic machines; passengers accustomed to mobile payments can generate e-tickets via the mobile app, avoiding the inconvenience of carrying physical tickets. E-tickets generated via the mobile app can be saved as screenshots, effectively resolving issues caused by unstable mobile networks within the station that prevent the ticket from being opened, ensuring smooth use for passengers.

[0069] Regardless of whether the terminal type is an automatic ticket vending machine or a mobile app-generated round-trip ticket, they are all based on the same code structure data, ensuring that ticket checking equipment such as gates can uniformly identify and verify them, avoiding ticketing system compatibility issues caused by terminal differences. Paper tickets support customized designs, while electronic tickets are convenient for passengers to store long-term, further enhancing the user experience.

[0070] Optionally, see Figure 5 Before step 1000, the following steps are also included: 1010: Obtain the ticket cover, font, and style of the ticket sales station to set the ticket customization data for the ticket sales station.

[0071] The system integrates the above elements into ticket customization data and synchronizes this data to the terminal devices at the corresponding stations.

[0072] The ticket cover is the visual design style of the front of the round-trip ticket, which can be freely configured through the online ticketing system to present different personalities for different scenarios. The settings dimensions include holidays, such as Spring Festival and National Day, large-scale events such as sports events and exhibitions, route features such as exclusive covers for airport express lines, station facilities, etc. For example, covers with landmark building patterns can be customized for popular stations.

[0073] The ticket font refers to the font style of the text printed on the round-trip ticket, such as the fare, release date, origin / destination station, and other key information. It allows for customizable settings to reflect individual preferences. The settings are consistent with the ticket cover; for example, a regular Song typeface can be used for weekdays, while an artistic font can be used for anniversaries.

[0074] Ticket style refers to the design style of the ticket cover and the font. It combines the time dimension of holidays, major events, and weekdays with the spatial dimension of different routes, popular stations, and terminal devices to form an overall visual effect. For example, the Spring Festival style can be matched with a red cover and gold foil font, while the technology route style can be matched with a blue cover and simple black font.

[0075] Customized ticket data is a structured collection of data that integrates customized parameters such as ticket cover, font, and style. It is generated by the online ticketing system through a visual interface and includes design rules corresponding to time / space dimensions, such as "all station terminals should use the National Day cover and KaiTi font during the National Day holiday." This data is synchronized to the ticketing terminals to guide them in generating personalized round-trip tickets.

[0076] 1020: Update the customized design of the round-trip ticket based on the ticket customization data.

[0077] The station terminal equipment receives and parses the ticket customization data, and dynamically adjusts the ticket design based on the cover, font, and style parameters in the data when generating round-trip tickets.

[0078] The customized design of the ticket cover, font, and style creates a distinctive visual effect, making the ticket both practical and commemorative, meeting passengers' needs for keeping and collecting, and enhancing their positive impression of rail transit services.

[0079] It supports customized ticket designs based on time and space dimensions, and can serve as a mobile promotional medium for rail transit companies to convey holiday greetings, event information, or line features, thereby enhancing brand recognition and cultural attributes.

[0080] 2000: In response to the round-trip ticket being recognized at the station's gate terminal and the round-trip ticket passing verification, the station's gate terminal is opened, and the status of the round-trip ticket is modified according to the station's location and the type of gate terminal.

[0081] Passengers scan their round-trip tickets at the gate terminal. The gate, by scanning and recognizing the QR code, sends a gate access monitoring request to the online ticketing system, submitting the code structure data. The online ticketing system performs multi-dimensional verification of the code structure data. If the verification passes, the online ticketing system returns an "open gate command," and the gate terminal controls the gate to open, allowing passengers to enter and exit the station. If the verification fails, the gate is refused and an invalid ticket is displayed.

[0082] A turnstile terminal is an automatic ticket checking device in rail transit stations used to identify, verify tickets, and control passenger entry and exit from paid areas. It is also known as an automatic gate machine (AGM) and includes both entry and exit gates. Its core function is to scan the ticket's QR code to initiate a verification request to the online ticketing system, control the gate's opening and closing based on system feedback, and record changes in ticket status.

[0083] The turnstile terminal automates the entire process—from automatic identification and real-time system verification to automatic gate opening—replacing traditional manual ticket checking and reducing passenger waiting time, significantly improving entry and exit efficiency, especially in high-traffic scenarios. Through multi-dimensional verification, it effectively identifies counterfeit, altered, or expired tickets, preventing invalid tickets from being used and reducing operational revenue risks. Simultaneously, a status modification mechanism ensures that tickets can only be used for the preset itinerary, avoiding duplicate or out-of-range travel.

[0084] Specifically, see Figure 6 The verification methods for round-trip tickets include: 2100: Verify the validity of the code structure data corresponding to the round-trip ticket.

[0085] Multi-dimensional security verification is performed on the code structure data of round-trip tickets to ensure that the data has not been forged or tampered with.

[0086] Furthermore, the legality of the code structure data corresponding to the round-trip ticket is verified, including: verifying the consistency of the issuing institution code of the round-trip ticket, verifying the timeliness of the round-trip ticket, verifying the device coding support status of the gate terminal, and verifying the consistency of the signature.

[0087] Verifying the consistency of the issuing institution code on the round-trip ticket involves using a public key to verify whether the issuing institution's authorized signature and the payment account user's private key signature match the original signature generated by the system's private key, thus preventing data tampering.

[0088] Verifying the validity of a round-trip ticket involves checking if the QR code is valid within the current operating day; if it has expired, it is considered an invalid ticket.

[0089] Verifying the device code support status of the inbound or outbound terminal involves checking whether the card issuing organization code is a system-approved organization and whether the device code is in the terminal device whitelist, thus excluding tickets issued by illegal devices.

[0090] 2200: In response to the code structure data passing the validity verification, verify the usage status of the code structure data.

[0091] Depending on whether the gate type is for entry or exit, the travel stage is for outbound or return journey verification status. For outbound or return journey entry, the ticket status must be unused or already exited; for outbound or return journey exit, the ticket status must be already entered, ensuring that the corresponding journey's entry operation has been completed.

[0092] 2300: In response to the use of status verification, the device code of the code structure data is verified to determine whether the station to which it belongs is consistent with the station where the round-trip ticket was sold.

[0093] The verification code structure data checks whether the station to which the device code belongs, i.e., the station where the terminal device that issued the round-trip ticket is located, is consistent with the ticket-selling station of the passenger's starting point. This ensures that the round-trip ticket can only be used at the station where it was sold. For example, if a passenger purchases a round-trip ticket at station A, they can only enter the station from station A or return to station A, preventing sales to other locations or unauthorized use.

[0094] By verifying the legitimacy of tickets, counterfeit and tampered tickets are completely blocked; by verifying the usage status, tickets are prevented from being reused; and by verifying the station consistency, tickets are prevented from being sold illegally in different locations. These three layers of logic form a closed-loop security protection system, reducing operational revenue risks.

[0095] Specifically, see Figure 7 Step 2000 also includes the following steps: 2400: In response to the round-trip ticket being recognized at the entry terminal of the ticketing station and the round-trip ticket passing verification, the exit terminal of the ticketing station is opened and the status of the round-trip ticket is changed to outbound entry.

[0096] Passengers scan their round-trip ticket QR code at the station's entry terminal. The terminal recognizes the QR code and verifies its validity; once verified, it opens the gate, allowing the passenger to enter the paid area; the system changes the round-trip ticket status from "unused" to "outbound entry" and records the entry time and station information.

[0097] 2500: In response to the round-trip ticket being recognized at the exit terminal of the destination station and the round-trip ticket passing verification, the exit terminal of the destination station is opened and the status of the round-trip ticket is changed to outbound exit.

[0098] After arriving at the destination station, passengers scan their tickets at the exit terminal. The gate verifies the validity of the QR code and ensures that the status is "outbound entry". Once the verification is successful, the exit terminal gate of the destination station opens, allowing passengers to leave the paid area. The system then changes the status of the round-trip ticket from "outbound entry" to "outbound exit", completing the one-way outbound journey.

[0099] 2600: In response to the round-trip ticket being recognized at the entry terminal of the target station and the round-trip ticket passing verification, the entry terminal of the target station is opened and the status of the round-trip ticket is changed to return entry.

[0100] Passengers returning from their destination station swipe their tickets at the station's entry terminal. The gate verifies the QR code's validity and ensures its status is "Outbound Exit" to confirm the outbound journey is complete. After successful verification, the gate opens, allowing the passenger to re-enter the paid area. The system then changes the round-trip ticket status from "Outbound Exit" to "Return Entry" and records the return entry time.

[0101] 2700: In response to the return ticket being recognized at the exit terminal and the return ticket passing verification, the exit terminal is opened and the status of the return ticket is changed to invalid.

[0102] Passengers return to the ticket-selling station and swipe their tickets at the exit terminal. The gate verifies the validity of the QR code and ensures its status is "Return Trip to Station". After successful verification, the exit terminal gate of the ticket-selling station opens, allowing passengers to leave the paid area. The system then changes the status of the round-trip ticket from "Return Trip to Station" to "Invalidated", rendering the ticket invalid.

[0103] Through state progression logic, the system automatically controls the permissions for the two trips of the round-trip ticket, eliminating the need for passengers to purchase tickets repeatedly or undergo manual verification. This adapts to business commuting, tourism, and other round-trip scenarios, improving travel convenience.

[0104] See Figure 8 , Figure 8 This is a schematic diagram of an embodiment of a single-ticket round-trip system for rail transit provided in this application. The single-ticket round-trip system for rail transit includes: Ticketing terminal 10 includes an automatic ticket vending machine and a mobile ticketing program. The automatic ticket vending machine is located in the non-paid area of ​​the station and is used to sell and print paper round-trip tickets. The mobile ticketing program is located in a mobile communication device and is used to sell and generate electronic round-trip tickets.

[0105] The ticketing terminal 10 is the equipment carrier for passengers to initiate ticket purchase requests, complete payment, and obtain round-trip tickets. It includes two types: automatic ticket vending machines and mobile ticketing programs, both of which are located in the non-paid area.

[0106] The automatic ticket vending machine receives passenger ticket purchase operations, such as selecting the destination station, quantity, and payment method, and completes cash or non-cash payment through the paper ticket issuance function interface; it sends a code generation request to the ticketing system 30, receives encrypted QR code data, and prints paper round-trip tickets on paper, with the ticket containing a QR code image and key information; it supports customized ticket printing: based on the ticket customization data issued by the ticketing system 30, it prints personalized paper tickets.

[0107] The mobile ticketing app provides the same ticketing interface as the automatic ticket vending machine. After passengers select their itinerary and complete the payment online, they send a code generation request to the ticketing system. After receiving the QR code data, the app generates a round-trip ticket in the form of an electronic image, which can be directly displayed in the app or saved as a screenshot. The electronic ticket has the same usage attributes as the paper ticket, and can be directly scanned to pass through the gate without worrying about damage or loss.

[0108] The turnstile terminal 20 includes an entry terminal 21 and an exit terminal 22. The entry terminal 21 is used to verify round-trip tickets to complete the passenger's entry, and the exit terminal 22 is used to verify round-trip tickets to complete the passenger's exit.

[0109] The turnstile terminal 20 is the core equipment for controlling passengers' entry and exit from the station. It includes an entry terminal 21 and an exit terminal 22. It realizes automated ticket checking by scanning the QR code of the round-trip ticket and dynamically updates the ticket status.

[0110] The entry terminal 21 scans the QR code on the passenger's round-trip ticket and sends a gate monitoring request to the ticketing system 30 via a socket channel to verify the legality of the verification code structure data. After successful verification, the gate is opened to allow the passenger to enter the paid area, and the ticketing system 30 is triggered to change the ticket status to "outbound entry" or "return entry".

[0111] The exit terminal 22 scans the QR code and verifies its legality, while also verifying the ticket status. After successful verification, the gate is opened to allow passengers to leave the paid area, and the ticketing system 30 is triggered to change the ticket status to "outbound exit" or "invalid".

[0112] The ticketing system 30 connects to the ticketing terminal 10 and the gate terminal 20 via an Internet device gateway. The ticketing terminal 10 and the gate terminal 20 send information to the ticketing system 30 through a socket channel to complete the above-mentioned round-trip ticketing method.

[0113] The ticketing system 30 connects to the ticketing terminal 10 and the gate terminal 20 through the "Internet device gateway". It is the core of realizing the one-ticket round-trip function and is responsible for processing ticket purchase requests, generating ticket data, verifying ticket information and managing the entire life cycle of the ticket.

[0114] The ticketing system 30 receives the code generation request from the ticketing terminal 10, generates code structure data containing 25 fields based on the passenger's ticket purchase information, encrypts it, and adds a signature.

[0115] The ticketing system 30 receives the gate monitoring request from the gate terminal 20 and completes the verification of the legality of the code structure data, the verification of its usage status, and the verification of station consistency.

[0116] The ticketing system dynamically updates the status of round-trip tickets every 30 minutes to ensure that the two round-trip trips are used in sequence.

[0117] The ticketing system 30 provides a visual interface for configuring the cover, font, and style of paper tickets, and synchronizes the configuration parameters to the ticketing terminal 10.

[0118] The ticketing system 30 interacts with the ticketing terminal 10 and the gate terminal 20 in real time through the socket channel, including receiving ticketing requests, issuing code data, receiving gate access requests, and returning verification results, ensuring fully automated processing.

[0119] Ticketing terminal 10 initiates a ticket purchase request, ticketing system 30 generates encrypted QR code data, ticketing terminal 10 outputs a paper electronic round-trip ticket, gate terminal 20 scans and verifies the ticket, ticketing system 30 verifies and modifies the status, completing two round-trip journeys. The three are seamlessly connected through an internet device gateway and socket channel, realizing a single ticket for round-trip travel with automatic management.

[0120] Unlike existing technologies, this application uses a QR code-based round-trip ticket to replace the traditional two-way single-journey ticket. The design features a paper QR code round-trip ticket that supports two round trips, with key information such as fare, release time, and origin and destination stations printed on the ticket, eliminating the need for gate collection. This eliminates the processes of ticket production, warehousing, transportation, and collection associated with traditional physical single-journey tickets, reducing operating costs. The transparent and intuitive ticket information solves the problem of ambiguous information on traditional physical tickets, increasing passenger trust. Furthermore, it allows for the purchase of a round-trip ticket in one transaction, replacing two single-journey tickets and reducing passenger queuing time.

[0121] This application also employs the SM2 national cryptographic algorithm to encrypt the code structure data, generating an authorization signature from the card issuer and a private key signature from the payment account user, which are then appended to the end of the code structure. The gate verifies the signature consistency using a public key. This prevents QR code data from being forged, tampered with, or expired, eliminating the risk of counterfeit tickets and ensuring the security of operational revenue. The public-private key verification mechanism ensures the integrity of data transmission and usage.

[0122] This application provides a visual interface that allows users to configure ticket covers, fonts, and styles according to time and space dimensions, and synchronize these configurations to the ticketing terminal for personalized ticket printing. This diversification of ticket designs enhances their commemorative value and increases passengers' willingness to collect them. Ticket designs can be dynamically updated without hardware modifications to adapt to the specific needs of temporary events or long-term routes, reducing operating costs.

[0123] This application supports two types of ticketing terminals: automatic ticket vending machines and mobile ticketing apps. Automatic ticket vending machines print paper tickets, while mobile ticketing apps generate electronic tickets. This caters to different user needs: users without smartphones can obtain paper tickets through automatic ticket vending machines, while mobile users can generate electronic tickets through mobile ticketing apps, improving convenience; electronic tickets reduce the workload of ticket processing due to damage or loss, further reducing operating costs.

[0124] This application constructs an internet-based ticketing system, serving as a central hub connecting ticketing terminals and turnstiles to automate the entire process, including ticket request processing, code data generation, verification logic execution, and status management. Replacing manual intervention, passengers can complete ticket purchase, printing, and station entry / exit self-service without registering an account, improving operational efficiency; real-time processing of ticketing data supports rapid response in high-concurrency scenarios.

[0125] By combining the aforementioned technical means, this application achieves full-process automation, reducing manual intervention and lowering costs associated with automatic ticket vending machine maintenance and ticket processing, thus adapting to the operational needs of large-scale rail transit networks. It supports both paper and electronic ticket modes, customized ticket designs, and one-time purchase for round-trip travel, resolving issues such as unclear information, cumbersome queuing, and easy loss of traditional single-journey tickets, thereby improving travel convenience and satisfaction. Multi-dimensional verification and dynamic status management form a closed-loop protection system, eliminating risks such as counterfeit tickets and unauthorized use, ensuring the ticketing system is secure and controllable. By eliminating the physical ticket collection process, reducing the workload of manual customer service, and dynamically adapting to operational scenarios, it lowers the overall operating costs of rail transit companies across multiple stages, including ticket production, maintenance, and management.

[0126] The above description is merely an embodiment of this application and does not limit the patent scope of this application. Any equivalent structural or procedural transformations made using the content of this application's specification and drawings, or direct or indirect applications in other related technical fields, are similarly included within the patent protection scope of this application.

Claims

1. A one-ticket round trip method for rail transportation, characterized by, The application relates to a method for generating a round-trip ticket, comprising: obtaining ticket information of a passenger in response to a ticket purchase request of the passenger to generate a round-trip ticket; opening a gate terminal of a station in response to the round-trip ticket being identified at the gate terminal of the station and the round-trip ticket passing a verification, and modifying a state of the round-trip ticket according to a location of the station and a type of the gate terminal.

2. The one-ticket roundtrip method of claim 1, wherein, The ticket information comprises a journey. The obtaining of the ticket information of the passenger to generate the round-trip ticket comprises: verifying whether a current rail transit configuration supports the journey; generating two-dimensional code data of the round-trip ticket based on the verified ticket information; generating the round-trip ticket based on the two-dimensional code data.

3. The one-ticket roundtrip method of claim 2, wherein, The generating of the two-dimensional code data of the round-trip ticket based on the verified ticket information comprises: configuring corresponding code data information according to the ticket information; assembling the code data information to generate code structure data; adding a signature to the code structure data to save as the two-dimensional code data.

4. The one-ticket roundtrip method of claim 3, wherein, The adding of the signature to the code structure data comprises: encrypting the code structure data by using an asymmetric encryption algorithm to generate a public key and a private key pair of the asymmetric encryption algorithm; adding the signature to an end of the code structure data by using the encrypted private key; and sending the public key to a ticketing terminal, and the public key is used to verify consistency of the signature.

5. The one-ticket roundtrip method of claim 4, wherein, The verification method of the round-trip ticket comprises: verifying legality of the code structure data corresponding to the round-trip ticket; verifying a use state of the code structure data in response to the code structure data passing the legality verification; verifying whether a station corresponding to a device code of the code structure data is consistent with a ticketing station of the round-trip ticket in response to the code structure data passing the use state verification.

6. The one-ticket roundtrip method of claim 5, wherein, The legality verification of the code structure data corresponding to the round-trip ticket comprises: verifying consistency of a card issuing agency code of the round-trip ticket, verifying time effectiveness of the round-trip ticket, verifying a support state of a device code of the gate terminal, and verifying consistency of the signature.

7. The one-ticket roundtrip method of claim 1, wherein, The ticket information further comprises ticketing terminal information. The obtaining of the ticket information of the passenger to generate the round-trip ticket further comprises: printing the round-trip ticket in a paper material in response to the ticketing terminal of the passenger being an automatic ticketing machine; or, generating the round-trip ticket in an electronic image form in response to the ticketing terminal of the passenger being a mobile ticketing program.

8. The one-ticket roundtrip method of claim 1, wherein, Before the obtaining of the ticket information of the passenger to generate the round-trip ticket, the method further comprises: obtaining a ticket surface cover, a ticket surface font and a ticket surface style of a ticketing station to set ticket surface customization data of the ticketing station; and updating a customized ticket surface of the round-trip ticket according to the ticket surface customization data.

9. The one-ticket roundtrip method of claim 1, wherein, The opening of the gate terminal of the station in response to the round-trip ticket being identified at the gate terminal of the station and the round-trip ticket passing the verification, and the modifying of the state of the round-trip ticket according to the location of the station and the type of the gate terminal, comprises: opening an outbound terminal of a ticketing station and modifying the state of the round-trip ticket to be a journey inbound in response to the round-trip ticket being identified at the inbound terminal of the ticketing station and the round-trip ticket passing the verification. in response to the round-trip ticket being identified at an exit terminal of a target station and the round-trip ticket being validated, opening the exit terminal of the target station and modifying the status of the round-trip ticket to outbound exit; in response to the round-trip ticket being identified at an entry terminal of the target station and the round-trip ticket being validated, opening the entry terminal of the target and modifying the status of the round-trip ticket to inbound entry; in response to the round-trip ticket being identified at an exit terminal and the round-trip ticket being validated, opening the exit terminal and modifying the status of the round-trip ticket to void.

10. A one-ticket round trip system for rail transportation, characterized by, comprising: a ticketing terminal comprising a ticket vending machine and a mobile ticketing program, the ticket vending machine being disposed in a non-fee area of a station for selling and printing a paper round-trip ticket, the mobile ticketing program being disposed in a mobile communication device for selling and generating an electronic round-trip ticket; a gate terminal comprising an entry terminal and an exit terminal, the entry terminal being used to validate the round-trip ticket to complete entry of a passenger, the exit terminal being used to validate the round-trip ticket to complete exit of the passenger; a ticketing system connecting the ticketing terminal and the gate terminal through an internet device gateway, the ticketing terminal and the gate terminal sending information to the ticketing system through a socket channel to complete the one-ticket round-trip method as claimed in any one of claims 1-9.